Hello,
I have written a Public shared Agent that exports selected E-Mails for a given user to a file for Optical storage. One of the fields used to identify the document in storage is the User's Name. I currently get the Username from the property "CommonUserName" from the Current Session. This works fine while users are archiving there own E-Mails, but it creates a problem when users Archive E-Mails on some else’s behalf. When I run my script on another users Mailbox from my notes session the E-Mails are identified as being mine instead of the proper user. This is a problem for the secretaries at my location for the do the Archiving for the Bosses.
So ultimately what I'm asking is how do you determine in LotusScript the Username on a specific Mailbox, not on a Specific Session?
Dim s As New notessession
Dim db As notesdatabase
Dim doc As notesdocument
Set db=s.currentdatabase
Set doc=db.getprofiledocument(
If doc.owner(0)<>"" Then
OwnerName=doc.owner(0)
End If