Lock opened files
Oxygen general issues.
-
- Posts: 96
- Joined: Mon May 09, 2011 11:54 am
Lock opened files
Hi,
is there a possibility to add a "lock" to opened files, so other users get a warning if there also try to open/edit an already opened file? This would be very useful if files are stored on a network share without a versioning system and multiple users have to edit them.
Thanks
Patrick
is there a possibility to add a "lock" to opened files, so other users get a warning if there also try to open/edit an already opened file? This would be very useful if files are stored on a network share without a versioning system and multiple users have to edit them.
Thanks
Patrick
-
- Posts: 9446
- Joined: Fri Jul 09, 2004 5:18 pm
Re: Lock opened files
Hi Patrick,
We have API like:
But Oxygen does not know if the file was already opened by other users.
Do you have this information on your side?
Also if you set a file as read-only on the network share (or on the local drive) Oxygen would show a small "lock" icon for it and show a warning when the user attempts to save it. This behavior is controlled by a checkbox in the Oxygen Preferences->"Editor" page called "Can edit read-only files":
http://www.oxygenxml.com/doc/ug-oxygen/ ... files.html
So another approach would be for the user who wants to edit a file to change its read-only flag using the Windows Explorer. Then after finishing, to reset the flag and save the modifications to it.
Regards,
Radu
We have API like:
Code: Select all
AuthorEditorAccess.setEditable(boolean editable)
Do you have this information on your side?
Also if you set a file as read-only on the network share (or on the local drive) Oxygen would show a small "lock" icon for it and show a warning when the user attempts to save it. This behavior is controlled by a checkbox in the Oxygen Preferences->"Editor" page called "Can edit read-only files":
http://www.oxygenxml.com/doc/ug-oxygen/ ... files.html
So another approach would be for the user who wants to edit a file to change its read-only flag using the Windows Explorer. Then after finishing, to reset the flag and save the modifications to it.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 96
- Joined: Mon May 09, 2011 11:54 am
Re: Lock opened files
No I have no information filesystem side, its a normal windows share. The workflow does not allow to set a file as readonly.
Oxygen could generate a second hidden file (sth. like filename.ext.lock) on open and delete it on closing a document. But if there are not such an option at this time, I try to find another solution.
Oxygen could generate a second hidden file (sth. like filename.ext.lock) on open and delete it on closing a document. But if there are not such an option at this time, I try to find another solution.
-
- Posts: 9446
- Joined: Fri Jul 09, 2004 5:18 pm
Re: Lock opened files
Hi Patrick,
Our plugins SDK allows you to create a "Workspace Access" plugin:
http://www.oxygenxml.com/oxygen_sdk.htm ... er_Plugins
Such a plugin would allow you to set a listener (ro.sync.exml.workspace.api.listeners.WSEditorChangeListener) which is notified before an URL is opened. Then you can check if there is a lock file next to it (and if so issue a warning that somebody is editing the file).
If there is no lock file next to it you create it and continue to open the URL.
Of course Oxygen also has an SVN client embedded so if you want true collaboration with file change history, check in and update capabilities + the possibility to tag certain releases, maybe you should consider installing an SVN server.
Regards,
Radu
How about if you generate the extra file when Oxygen opens a document?Oxygen could generate a second hidden file (sth. like filename.ext.lock) on open and delete it on closing a document.
Our plugins SDK allows you to create a "Workspace Access" plugin:
http://www.oxygenxml.com/oxygen_sdk.htm ... er_Plugins
Such a plugin would allow you to set a listener (ro.sync.exml.workspace.api.listeners.WSEditorChangeListener) which is notified before an URL is opened. Then you can check if there is a lock file next to it (and if so issue a warning that somebody is editing the file).
If there is no lock file next to it you create it and continue to open the URL.
Of course Oxygen also has an SVN client embedded so if you want true collaboration with file change history, check in and update capabilities + the possibility to tag certain releases, maybe you should consider installing an SVN server.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ Artificial Intelligence (AI Positron Assistant add-on)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service