Information générale
Catégorie:
COM/DCOM et OLE Automation
Titre:
Notes object model ( accessing Address book through COM )
Hi Ariel,
I saw your thread regarding accessing Lotus Notes Address book from VFP as i am looking something similar to do with Notes.
I want to loop through Notes Address book ( i.e. Contacts ) and read the values like FirstName, lastName, MobilePhoneNumber etc..
I find out lObject = GetNextDocument(DomDoc) skips to next document( record ).
Domsession = createobject("Notes.Notessession")
*Domsession = createobject("Lotus.Notessession")
DomDir = Domsession.GetDatabase("","names.nsf")
DomContacts = DomDir.GetView("People")
DomDoc = DomContacts.GetFirstDocument()
DomItem = DomDoc.GetFirstItem("LastName")
if vartype(DomItem) = "O"
?DomItem.text && this will print Lastname from Contacts
* StrName = DomItem.Value(0) && this gives error
endif
DomItem = DomDoc.GetFirstItem("FirstName")
?DomItem.text && prints firstname
Just one more thing.
When I run this code it opens up Notes in the background. Is there a way i don't see this.
Regards
Dejan Jocic
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement