TMail Class

TMail Class

Postby MarcoBoschi » Mon Oct 10, 2016 12:14 pm

I have to set sender field

...
LOCAL aSend := { "m.boschi@marcoboschi.it" , "info@marcoboschi.it" }
...
DEFINE MAIL oMail ;
SUBJECT cSubject ;
FROM USER ;
TEXT cText
...
oMail:aOrigin := aSend
...
ACTIVATE MAIL oMail

Is it correct?

Many Thanks
Marco
User avatar
MarcoBoschi
 
Posts: 1065
Joined: Thu Nov 17, 2005 11:08 am
Location: Padova - Italy

Re: TMail Class

Postby Enrico Maria Giordano » Mon Oct 10, 2016 1:37 pm

No:

Code: Select all  Expand view
LOCAL aSend := { { "m.boschi@marcoboschi.it", NIL } , { "info@marcoboschi.it", NIL } }

...

oMail:aRecipients := aSend


EMG
User avatar
Enrico Maria Giordano
 
Posts: 8710
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: TMail Class

Postby MarcoBoschi » Sat Mar 04, 2017 5:51 pm

Hi,
I have to send email in a pc with Outlook 2010 installed.

How should I initialize array containing Reipients?

Enrico a few months ago write to me this
in this topic

http://forums.fivetechsupport.com/viewtopic.php?f=3&t=33046&p=194607&hilit=marco+boschi#p194607
Code: Select all  Expand view

LOCAL aSend := { { "m.boschi@marcoboschi.it", NIL } , { "info@marcoboschi.it", TO_VALUE } }

LOCAL aSend := { { "m.boschi@marcoboschi.it", TO_VALUE } , { "info@marcoboschi.it", CC_VALUE } }
 


here there is some documentation

https://msdn.microsoft.com/en-us/library/office/ff863703.aspx

https://msdn.microsoft.com/en-us/library/office/ff866751.aspx

Many thanks
User avatar
MarcoBoschi
 
Posts: 1065
Joined: Thu Nov 17, 2005 11:08 am
Location: Padova - Italy

Re: TMail Class

Postby MarcoBoschi » Sat Mar 04, 2017 5:59 pm

maybe in this way?

Code: Select all  Expand view
oRecip:Add( "info@marcoboschi.it" )
oRecip:Add( "m.boschi@marcoboschi.it" )
oRecip[ 1 ]:Type := 1
oRecip[ 2 ]:Type := 2
 


It works.....
User avatar
MarcoBoschi
 
Posts: 1065
Joined: Thu Nov 17, 2005 11:08 am
Location: Padova - Italy


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 79 guests