Thanks to all who responded.
Garry, your code works with my parameters.

Thank you.

Now, how do I read email using thunderbird client?
Can I do it with cdo, mapi or some other product.

All this from inside VFP of course.

TIA,
Mike

On 08/04/2012 2:09 PM, Garry Bettle wrote:
> TRY
>    LOCAL lcSchema, loConfig, loMsg, loError, lcErr
>    lcErr = ""
>    lcSchema ="http://schemas.microsoft.com/cdo/configuration/";
>    loConfig = CREATEOBJECT("CDO.Configuration")
>    WITH loConfig.FIELDS
>      .ITEM(lcSchema + "smtpserver") = "smtp.gmail.com"
>      .ITEM(lcSchema + "smtpserverport") = 465&&  รณ 587
>      .ITEM(lcSchema + "sendusing") = 2
>      .ITEM(lcSchema + "smtpauthenticate") = .T.
>      .ITEM(lcSchema + "smtpusessl") = .T.
>      .ITEM(lcSchema + "sendusername") ="*****.*****@gmail.com"
>      .ITEM(lcSchema + "sendpassword") = "**********"
>      .UPDATE
>    ENDWITH
>    loMsg = CREATEOBJECT ("CDO.Message")
>    WITH loMsg
>      .Configuration = loConfig
>      .FROM ="*****.*****@gmail.com"
>      .TO ="*****.*****@gmail.com"
>      .Subject = "Test from Gmail"
>      .TextBody = "This is a test message with CDO " + ;
>        "SSL authentication and encryption from Gmail"
>      .Send()
>    ENDWITH
> CATCH TO loError
>    lcErr = [Error: ] + STR(loError.ERRORNO) + CHR(13) + ;
>      [Line: ] + STR(loError.LINENO) + CHR(13) + ;
>      [Message: ] + loError.MESSAGE
> FINALLY
>    RELEASE loConfig, loMsg
>    STORE .NULL. TO loConfig, loMsg
>    IF EMPTY(lcErr)
>      MESSAGEBOX("The message was sent successfully", 64, "Notice")
>    ELSE
>      MESSAGEBOX(lcErr, 16 , "Error")
>    ENDIF
> ENDTRY

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: http://leafe.com/archives/byMID/profox/[email protected]
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to