I have multiple work stations that have read only access to a shared folder.
Every time they try to open a file it says document is in use.
Is there a way to automatically select “Open Read-Only” so it quits asking the question?
I have multiple work stations that have read only access to a shared folder.
Every time they try to open a file it says document is in use.
Is there a way to automatically select “Open Read-Only” so it quits asking the question?
Do you (and the other users) want edit and re-save those documents, or those files are some templates only (that you will store by usage of the Save_as with a different path and filename for the save)?
Actually with Calc you can, to a limited extent. See Sharing Spreadsheets .
But that’s not what the question implies. And no, AFAIK that dialog can not be suppressed.
I don’t get any such message when I open a read-only document. This message indicates a lock file. If you changed the file access mode while the document was opened for editing, any program loaded by normal users can not remove the lock file.
Get write access to the folder in question and remove .~lock.2021.xlsm#
It’s not clear from the question, but I think that at least one user has the file open with write access and hence created the lock file or some network locking is in effect, and every user with read-only access gets the dialog. The questioner @dorno83 should edit the question and clarify.
I opened up at least 50 files and every time the question is asked.
So I am assuming the file is not opened for editing and locked mainly because the people that work on them only work on one at a time.
So the question now would be why and how they could be getting into this “locked” state
We have all the files on a local server and have the folder shared but we have the folder as read access NOT read/write
Must be one of these Windows issues. Works OK on a regular operating system. I make the file or its entire directory read-only and the operating system does not claim that the file is in use by someone else.
Finally I could reproduce the issue on a Linux box. It occurs when I don’t have permission to create files in the folder while the contained files are writable. Make all the files read-only before restricting the folder permissions and remove any existing lock files. I don’t have access to a Windows machine right now.
If @Villeroy’s discovery applies to your case, then it looks like LibreOffice has pointed to a real problem in your network configuration, where you can in fact change files that you consider read-only, and only LibreOffice’s failure to create a lock file allowed to see that.
Shouldn’t LO distinguish between existing lock files and lock files that can’t be created?
It does, and in case of existing lock files, shows you a “locked by … at …” message
@dorno83, could you please specify the operating system on which LO is running and the operating system on which the shared folder is located?
The task bar on the screenshot indicates Windows.
Thanks, I’m not that observant.
On Windows, I manage to reproduce this behavior on my computer (which is part of a domain) using the method indicated by @Villeroy :
I would venture to suggest that when opening a file, access rights to the folder are not taken into account.
I checked: in Excel, in such a situation, the file opens as ReadOnly without issuing a warning.
I found a file in the LO installation, when opened, the indicated effect occurs:
"C:\Program Files\LibreOffice\help\media\files\scalc\pivot.ods
On Linux the files contained in the installation folder are read-only for any user → opens normally in read-only mode.
Aha; so it looks like the error status that LibreOffice gets on different systems (Linux vs Windows) differ in the “same” case: in Windows, the files are also unmodifiable for users, and LibreOffice fails to open it for editing, but the outcome is different. I will see to file a bug report detailing the difference.
tdf#150118 filed.
LO is running on Windows 10 and the files are saved to Windows Server 2013 I believe.