Alford Miller
asked on
What permission need to be set to use a Documents Save method on another users Mailbox
Hello,
I have a script that Creates a tag Item on a document that indicates processing. here is a code snippet:
Set oGaussItem = Nothing
Do While oGaussItem Is Nothing
Set oGaussItem = oDoc.GetFirstItem(cGaussIt em)
If oGaussItem Is Nothing Then
Call oDoc.AppendItemValue( cGaussItem, 0)
Call oDoc.Save( False, False)
End If
Loop
This code works fine until it is run against another users Mailbox which yields "Notes error: You are not authorized to perform that operation". Under "Delegations" my test user has given me access to Read, Delete, Edit, Send E-Mail in there name. What other permissions are need?
PS. This Script is being run as a shared agent from the client side and triggerd from "Action Menu". The Action is stored and called from the Test Users Mailbox by myself after Opening the Test Users Database from within my notes session.
I have a script that Creates a tag Item on a document that indicates processing. here is a code snippet:
Set oGaussItem = Nothing
Do While oGaussItem Is Nothing
Set oGaussItem = oDoc.GetFirstItem(cGaussIt
If oGaussItem Is Nothing Then
Call oDoc.AppendItemValue( cGaussItem, 0)
Call oDoc.Save( False, False)
End If
Loop
This code works fine until it is run against another users Mailbox which yields "Notes error: You are not authorized to perform that operation". Under "Delegations" my test user has given me access to Read, Delete, Edit, Send E-Mail in there name. What other permissions are need?
PS. This Script is being run as a shared agent from the client side and triggerd from "Action Menu". The Action is stored and called from the Test Users Mailbox by myself after Opening the Test Users Database from within my notes session.
I hope you are trying to access somebodies mail box and update the documents.. Basically the mail file is always protected so that other users doesn't tamper the mails of the owner. Only the owner and administrator group has access to this mail file.
If you are collecting some statistics, then sign the agent with admin id and schedule it to run hourly or daily depending upon the need .
If you are collecting some statistics, then sign the agent with admin id and schedule it to run hourly or daily depending upon the need .
ASKER
The script resides in a "Agent" that is called manually from a "Action" on the "Action Menu". This "Action" has to be callable by both the User and anyone who has been given the option to access there Mailbox. Obviously Edit Mail rights are necessary, but my script fails even when I grant full access to the Mailbox.
Does this document has Authors field ? If so list the current username in this field
ASKER
The Document is a E-Mail.
Probably the problem should be somewhere else.. If you can guide me on how and what you are doing then I can identify the problem.
Make that agent schedule and this agent should be signed by admin id.
This will have access to all mail databases and it will create documents/ or u can do anything with this agent.
And as for your requirement, what I understood is , u want to trigger some code through action button and access other mail databases. U need to follow below steps to do:
u need to have editor access to that mail database
That mail db should be residing on your workspace
And if u can place ur code, we will look into it and tell whats going wrong.
This will have access to all mail databases and it will create documents/ or u can do anything with this agent.
And as for your requirement, what I understood is , u want to trigger some code through action button and access other mail databases. U need to follow below steps to do:
u need to have editor access to that mail database
That mail db should be residing on your workspace
And if u can place ur code, we will look into it and tell whats going wrong.
ASKER
Hello HemanthaKumar,
This is what I am trying to do: I am trying to interface Lotus Notes with our legacy Document Management (Gauss) system for storage of electronic documents that may potentially have legal bearing onto Optical Storage. So far, I have been able to create "Agents" to send documents from Notes into our Gauss. These "Agents" are called from "Actions" in the "Action" Menu. The problem that I am running into, or more accurately trying to avoid is duplicate entries of the same document in the Gauss system. The Easiest way I can think of to prevent duplication was to Add a Item to the that will keep track of what was already sent, I'll explain in suto code using my earlier sample code as a reference.
For clarities sake, here is a description of the variables being used:
a) oDoc - NotesDocument Object containing Document to be Archive.
b) oGaussItem - NotesItem Object containing status indication.
c) cGaussItem - Constant (String) containing name of oGaussItem.
The status indicator item (oGaussItem) should hold one of three values:
a) 0 to indicate document is about to be Optically Archived.
b) 1 to indicate document was Successfully archive in the past.
c) -1 to indicate document had attempted to be archived but failed.
Here is the Sudo code:
1) Check if Document Has indicator item {Set oGaussItem = oDoc.GetFirstItem(cGaussIt em)}
1a) If no indicator exists, add indicator to document and give it a value of 0 {Call oDoc.AppendItemValue( cGaussItem, 0)}
1b) save document so that status indicator is attached to document {Call oDoc.Save( False, False)}
2) If indicator is one, warn user that they are creating a duplicate in Optical Archive and give user choice if they are to continue. Exit function if they decline.
3) Export Document from notes and Send it to Optical Storage using API from Gauss.
4) Mark indicator with either 1 or -1 based on success or failure indication for Optical Storage API.
5) save status of Indicator to document.
All this works fine if the user is operating from there own mailbox. My problem comes about from the fact that some user have assistants that they have given access to there mailbox and these assistants have to be able to use my "Agents" to send documents to Optical Storage on there bosses behalf, but my "Agent" fails when the "save" method is called to save the status indicator on there bosses E-mail resulting in "Notes error: You are not authorized to perform that operation". The "save" method fails even if the assistant is given the Authority to "Edit E-Mails" on there bosses mailbox.
So at this point, I am at a loss on how to get past this error.
This is what I am trying to do: I am trying to interface Lotus Notes with our legacy Document Management (Gauss) system for storage of electronic documents that may potentially have legal bearing onto Optical Storage. So far, I have been able to create "Agents" to send documents from Notes into our Gauss. These "Agents" are called from "Actions" in the "Action" Menu. The problem that I am running into, or more accurately trying to avoid is duplicate entries of the same document in the Gauss system. The Easiest way I can think of to prevent duplication was to Add a Item to the that will keep track of what was already sent, I'll explain in suto code using my earlier sample code as a reference.
For clarities sake, here is a description of the variables being used:
a) oDoc - NotesDocument Object containing Document to be Archive.
b) oGaussItem - NotesItem Object containing status indication.
c) cGaussItem - Constant (String) containing name of oGaussItem.
The status indicator item (oGaussItem) should hold one of three values:
a) 0 to indicate document is about to be Optically Archived.
b) 1 to indicate document was Successfully archive in the past.
c) -1 to indicate document had attempted to be archived but failed.
Here is the Sudo code:
1) Check if Document Has indicator item {Set oGaussItem = oDoc.GetFirstItem(cGaussIt
1a) If no indicator exists, add indicator to document and give it a value of 0 {Call oDoc.AppendItemValue( cGaussItem, 0)}
1b) save document so that status indicator is attached to document {Call oDoc.Save( False, False)}
2) If indicator is one, warn user that they are creating a duplicate in Optical Archive and give user choice if they are to continue. Exit function if they decline.
3) Export Document from notes and Send it to Optical Storage using API from Gauss.
4) Mark indicator with either 1 or -1 based on success or failure indication for Optical Storage API.
5) save status of Indicator to document.
All this works fine if the user is operating from there own mailbox. My problem comes about from the fact that some user have assistants that they have given access to there mailbox and these assistants have to be able to use my "Agents" to send documents to Optical Storage on there bosses behalf, but my "Agent" fails when the "save" method is called to save the status indicator on there bosses E-mail resulting in "Notes error: You are not authorized to perform that operation". The "save" method fails even if the assistant is given the Authority to "Edit E-Mails" on there bosses mailbox.
So at this point, I am at a loss on how to get past this error.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Hello HemanthaKumar,
Sorry I took so long to answer but I had thought I had closed this case already. Cheers!
Sorry I took so long to answer but I had thought I had closed this case already. Cheers!
~Hemanth