How get message from dbx (Outlook Express)
Posted: Mon Apr 30, 2007 10:57 pm
Hi, i need to know all the folders and messages in the outlook express or microsoft outlook or more in general in the default mail of pc.
I found the following exampe for microsoft outlook and in tried to implement it.
****************************
oOL := TOleAuto():New( "Outlook.Application" )
lOutlookOK := .T.
IF ! lOutlookOK
RETURN ( 0 )
ENDIF
oNameSpace = oOL:Get( "GetNameSpace", "MAPI" )
oContacts = oNameSpace:Get( "GetDefaultFolder", "6" ) // 6 = Inbox-Folder
FOR nContador = 1 TO oContacts:ITEMS:Count()
oNewContact = oContacts:ITEMS( nContador )
cSenderName := oNewContact:get( "SenderName" )
cSubject := oNewContact:get( "Subject" )
cBody := oNewContact:get( "Body" )
NEXT nContador
RETURN NIL
********************
of course i dont know how to complete it.
I need for example to have all the folders of default mail (express/outlook/other) and the message and all the other information from an email/msg
Tks
Romeo
I found the following exampe for microsoft outlook and in tried to implement it.
****************************
oOL := TOleAuto():New( "Outlook.Application" )
lOutlookOK := .T.
IF ! lOutlookOK
RETURN ( 0 )
ENDIF
oNameSpace = oOL:Get( "GetNameSpace", "MAPI" )
oContacts = oNameSpace:Get( "GetDefaultFolder", "6" ) // 6 = Inbox-Folder
FOR nContador = 1 TO oContacts:ITEMS:Count()
oNewContact = oContacts:ITEMS( nContador )
cSenderName := oNewContact:get( "SenderName" )
cSubject := oNewContact:get( "Subject" )
cBody := oNewContact:get( "Body" )
NEXT nContador
RETURN NIL
********************
of course i dont know how to complete it.
I need for example to have all the folders of default mail (express/outlook/other) and the message and all the other information from an email/msg
Tks
Romeo