We have a view which gives users an ability to work with documents where we made our own logic for copying documents. It is accessed with a special button on the view. But the standard behavior of copy paste key shortcuts is still there and some users are using it instead and this is breaking some of our logic.
Is there any way to prevent users to copy \ paste documents within Lotus database or at least a certain view?
Yes. If the user don't have author/editor/depositor access they can't paste documents into the database.
You also have the QueryPaste event in the view, you can use that to prevent documents from being pasted in.
In Notes 8.0.2 you also got a new database property (under the advanced tab) called "disable export of view data". You can use that one as well.
There is also a 'disable copy' system field you can apply to any document. If the document contains a field called $KeepPrivate with a value of "1" then document copying is prevented in the client UI. It prevents copying to the clipboard and printing out. It doesn't prevent screen-print of course. It doesn't prevent pasting in either (see paste agents to control that). Readers cannot paste in a document or edit existing data too. You can set/clear $KeepPrivate as needed and $Readers too if necessary.
Related
In LN 6.5.6 i have a view with a lot of type of documents(with different form and fields) and i want to create a preview mode of that document using:
dynamic form: User select a document and a script compose a form with all fields of that document and open it with DialogBox method. (i must have to create a new form because the database do not cointain any form, forms are in other databases)
OR
dynamic view: User select a document and a script compose a view with all fields of that document and open it.
Is this possible?
Sure, it's possible. Just have the script copy the document to a temporary NSF file that contains whatever forms or views you want, and then bring up the dialog from there. The problems, though, are that when the user exits the dialog they'll find themselves in the temporary database instead of where they expected to be, and you'll probably need a way to clean up the temporary database, too.
Or for the view idea, your script can create a temporary folder with the columns that you want, put the selected document in the folder, and then open the folder. Again, though, the problem is that the user will not really know where he is and how to get back where he was, and you'll have to figure out a way to clean up the temporary folders.
Why not instead just add a form to the database, make it the default form, and just give it all the fields it needs for your previews of the fields you want from documents of different types?
I am developing a database on Lotus Designer 8.5 environment with LotusScript and LotusFormula.
Is there any possibilities on get a list of recently opened documents (for example last five) in a Lotus Notes database ? My purpose is to provide an embedded view showing the recent documents opened by current user on the current database, which will act like some kind of history view.
Please advise
Use a folder categorized by username. Add the current document in PostOpen event to folder with document.PutInFolder(folderName) and remove the oldest document from folder with document.RemoveFromFolder(folderName)
This way you don't need to edit the documents and can show the last visited documents for a user in an embedded view.
As an alternative you can use user specific folders with option "Shared, private on first use".
I have that functionality in one of my databases.
I just added some code in the QueryOpen event of the form to store the UNID of the document in a profile document linked to the specific user. The values are stored in a multi value field, and my code removes the oldest entry when the number of entries I want to store is exceeded.
The user can actually set that number themselves in teh applications settings, 5 is default but they can make it more or less.
I built a class for this, makes it very easy to modify later, and to implement it in different forms, for different document types.
I then built a method to expose the last documents to the user, using a dropdown box as you can see below. Since you only wwant/need the five (or perhas ten) last documents, no need to use a view.
There is a Lotus Notes application containing >8k documents, listed by some views.
A user showed this error, while he tried to copy ( from one document being in read-mode, we tried also in edit-mode ) some content ( value fields ) to another document ( into some fields ). Strangely, the error is showing only for a certain document ( of course we didn't try for all of 8k docs, but we try for other 5-6 docs and the error didn't showed up. )
You cannot forward or otherwise copy the contents of this document.
This document is set to prohibit copying and duplicating.
I read that it might be an admin problem. How can I resolve this issue?
The document has probably a field $KeepPrivate set to "1". If you delete the field you can copy the content into clipboard again.
As a developer you can let create such a field for documents if you set option "Disable printing/forwarding/copying to clipboard" in security tab in form properties.
The $KeepPrivate item that Knut described may exist because of an ACL setting instead of the Form setting. There is a setting on each ACL entry labeled 'Replicate or copy documents'. Users who do not have this setting enabled will not be able to copy documents, but there is a side effect which is described in this IBM Technote. I.e., when a user who has this ACL setting creates documents, those documents are marked with the $KeepPrivate item. This prevents everyone from copying the document, even people who don't have that box checked in their own ACL entries. IBM does not consider this a bug. I consider it a design flaw.
I have a legacy Lotus Notes application that starts to randomly lock a document even though no one is opening the document. So when someone tries to edit a document, Notes will say that 'the document is locked by user1/Domain' but when I check with user1, the person does not have that document open and the admin or the user1 has to manually right click the document and select 'Unlock document'.
What would some suggestions to try to find out the cause of this problem?
If users aren't manually locking the documents, then there must be some code that is doing it on their behalf. Look through the code for places where the NotesDocument.Lock() method is being used or the formula #DocLock
I would use the Design Synopsis feature to generate a report of all the forms, script libraries, and agents, and then do a text search for those methods/formulas. That may help narrow down where the lock is occurring.
Or, if you wish to turn off document locking completely:
Choose File - Application - Properties and click the Basics tab.
Deselect "Allow document locking."
Very new to Lotus designer.
I am trying to create a simple form with a field which is updated from time with additional information. I want the admin user to be able to update this information on the same form interface as the user viewing the information.
It appears I do not really understand how to get the form to display information entered into it previously.
I did Ctrl+shift view of the database and saw all the previous entries but I can not seem to get the form to display these information as well as allow me to append to them.
Kindly help.
Thanks.
Have a look at the online Domino Designer help - for instance the sections on designing forms:
http://publib.boulder.ibm.com/infocenter/domhelp/v8r0/topic/com.ibm.designer.domino.main.doc/H_ABOUT__FORMS.html
A form is used to create a new document or to edit an existing document. Since you say that you can see the previous entries, you must be creating a new document for each entry.
If you want to see and modify the contents of an existing document, you have to navigate to the document and open it for edit.
If you want the user to see a list of all the previous documents while he is creating a new one, you can add an embedded view to the form and use that to display data from the previous documents.
If you want all the information to be in a single document, then you need to stop creating new documents and just select the exiting document, open it for edit, make your changes, and re-save the document.