kfschaefer
Programmer
I currently have a database that has multiple spreadsheets linked to the mdb. How do I handle the issue of Multiple users at the same time or if a users forgets to close a linked xls and prevents the admin from running the nightly updates?
There is no particular security besides the network sercurity. Also, multiple users may be access the same xls at the same time.
Is there a way to kick out someone and force the xls to close?
Note: MSDE not an option - and my database is the backend to the various spreadsheets. My client does not actual open Access - I am the only user of Access and this process is run nightly - except stops if a users forgot to close the xls.
I also looked he example that verifies if Excel wkbook open forces to close, unfortunately, due to security issues, I believe this could be a problem - due to the fact I will not have admin writes to the server that will allow me to kick the user off.
I also tried;
Private Function IsFileAlreadyOpen(Filename As String) As Boolean
' Returns TRUE if the workbook is open
Dim xlapp As Excel.Application ' be sure to be explicit about your object definitions, it will speed up your code and make it easier to debug
Dim xlwk As Excel.Workbook
Set xlapp = GetObject(, "Excel.Application")
Debug.Print xlapp.Workbooks.Count
For Each xlwk In xlapp.Workbooks
Debug.Print xlwk.Name
Next xlwk
xlapp.Quit
End Function
this works great if the spreadsheet is on my machine - but the spreadsheets will be accessed via the server and I need to be able to closes them no matter who or where.
Thanks,
Karen
There is no particular security besides the network sercurity. Also, multiple users may be access the same xls at the same time.
Is there a way to kick out someone and force the xls to close?
Note: MSDE not an option - and my database is the backend to the various spreadsheets. My client does not actual open Access - I am the only user of Access and this process is run nightly - except stops if a users forgot to close the xls.
I also looked he example that verifies if Excel wkbook open forces to close, unfortunately, due to security issues, I believe this could be a problem - due to the fact I will not have admin writes to the server that will allow me to kick the user off.
I also tried;
Private Function IsFileAlreadyOpen(Filename As String) As Boolean
' Returns TRUE if the workbook is open
Dim xlapp As Excel.Application ' be sure to be explicit about your object definitions, it will speed up your code and make it easier to debug
Dim xlwk As Excel.Workbook
Set xlapp = GetObject(, "Excel.Application")
Debug.Print xlapp.Workbooks.Count
For Each xlwk In xlapp.Workbooks
Debug.Print xlwk.Name
Next xlwk
xlapp.Quit
End Function
this works great if the spreadsheet is on my machine - but the spreadsheets will be accessed via the server and I need to be able to closes them no matter who or where.
Thanks,
Karen