Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel shared file
Is there any way to getting a list (with the help of VBA) of who is
opening an excel shared file ? Thank you |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel shared file
Hi Gabriel;
Private Sub UsersList() Dim users, msg As String, status As String users = ThisWorkbook.UserStatus For Row = 1 To UBound(users, 1) msg = msg & users(Row, 1) & " " & Format(users(Row, 2), "dd/mm/yy h:mm") & " " If users(Row, 3) = 1 Then status = "(Exclusive mode)" Else status = "(Shared mode)" msg = msg & status & vbLf Next MsgBox msg, 64 End Sub MP "Gabriel" a écrit dans le message de om... Is there any way to getting a list (with the help of VBA) of who is opening an excel shared file ? Thank you |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel shared file
Michel ... UserStatus property is the good one but unfortunately is not useful if you have to open the file as read-only. So back to square one: if you want to trap an error (e.g. trying to save a file that is already open by someone else) you have to use something else and I don't know what to do
----- Michel Pierron wrote: ---- Hi Gabriel Private Sub UsersList( Dim users, msg As String, status As Strin users = ThisWorkbook.UserStatu For Row = 1 To UBound(users, 1 msg = msg & users(Row, 1) & " " & Format(users(Row, 2), "dd/mm/yy h:mm" & " If users(Row, 3) = 1 Then status = "(Exclusive mode)" Else status "(Shared mode) msg = msg & status & vbL Nex MsgBox msg, 6 End Su M "Gabriel" a écrit dans le message d om.. Is there any way to getting a list (with the help of VBA) of who i opening an excel shared file Thank yo |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel Shared File | Excel Discussion (Misc queries) | |||
Shared Excel File | Excel Worksheet Functions | |||
rename shared Excel file | Excel Discussion (Misc queries) | |||
shared excel file | Excel Discussion (Misc queries) | |||
Shared Excel file | Excel Discussion (Misc queries) |