Not sure what you mean by "Location" but that code (for the other informations) should work. Copy and paste in the post open event of your form.
<pre>
Set ws = New NotesUIWorkSpace
Set session = New NotesSession
Set db = session.CurrentDatabase
Set uidoc = ws.CurrentDocument
Set dbPAB = session.GetDatabase( db.Server, "NAMES.NSF", False )
if not dbPab is nothing then
set viewPab = dbPab.GetView( "($Users)" )
set docPab = viewPab.GetDocumentByKey( session.UserName, True )
if not docPab is nothing then
if not uidoc.EditMode = True
uidoc.editMode = True
end if
call uidoc.FieldSetText( "YourFieldName_NAME_Here" , docPab.FullName(0)
call uidoc.FieldSetText( "YourFieldName_PHONE_Here" , docPab.OfficePhoneNumber(0)
call uidoc.FieldSetText( "YourFieldName_TITLE_Here" , docPab.JobTitle(0)
end if
else
MessageBox "Public Adress Book can not be accessed !", 64, "Error"
end if
</pre>
end if
Last Wiki Answer Submitted: September 29, 2011 1:33 pm by BruceWayne4,075 pts.
All Answer Wiki Contributors: BruceWayne4,075 pts.
If you live outside the United States, by submitting your email address you consent to having your personal data transferred to and processed in the United States.