Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Sending email within VFP
Message
 
 
To
13/10/2006 09:24:31
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
01160261
Message ID:
01162662
Views:
22
Hi...
The problem was solved a few days ago.. (with Jim Booth's help) this is the source code (several values were changed):
oMSG = createobject("CDO.Message")
oMSG.From = "SENDER_NAME"
oMSG.To = "email_1@domain.com; email_2@domain.com; email_3@domain.com"
oMSG.CC = "email_4@domain.com; email_5@domain.com; email_6@domain.com"
oMSG.Subject = "This is the email's subject."
oMSG.TextBody = "Greetings."+chr(13)+"This is the email's body (content)"
oMSG.AddAttachment('full_path_and_name_to_the_attach')
oMsg.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
oMsg.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "mailservername"
oMsg.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
oMsg.Configuration.Fields.Update
oMSG.Send()
I hope this helps..


>>Hi Fabio,
>>
>>I am considering releasing the source code to all of the FLLs I have created out on VFPX (assuming the projects were accepted for inclusion), but that's probably the only place I would release the source. If a Visual FoxPro community member was adept at working in VC++ and building FLLs I would also consider working with them on an individual basis to improve the FLLs and write more of them for use by the Visual FoxPro Community. As an aside, if you download the Code Project that I reference in my blog entry concerning this FLL you'll have most of the working source that is needed to create a working Extended MAPI FLL. The C++ wrappers there are quite good (though they rely on MFC which you would need to remove dependency from).
>>
>
>Thanks.
>
>>I'm curious, what is it that you are finding particular arduous about not having the source to this FLL?
>>
>
>There are two motives:
>- the first one is that the whole code that I see writing in the web and in the books,
>is written thinking that they work, this is very simple to be done.
>Normally I write the code thinking about all the cases in which it cannot work,
>and I try to minimize the number of these cases before to write the first line.
>
>- I can use only them in an application if I have the guarantee that exists a way to correct the errors
>for at least 10 years, otherwise, if I don't have the source code, I don't waste time to integrate them.
>
>Of course, VFP, SQL SERVER, VC++, Windows and the HW are exceptions to these rules.
>
>Fabio
>
>>>Hi Craig,
>>>
>>>Could you publish the source codes.
>>>
>>>It is arduous to use a black box library.
>>>
>>>Thanks
>>>
>>>>Hi Jonathan,
>>>>
>>>>One way to circumvent the Outlook security dialog is to use Extended MAPI instead of Simple MAPI. See the following for an FLL I just finished to handle this...
>>>>
>>>>http://www.sweetpotatosoftware.com/SPSBlog/PermaLink,guid,baccc84d-4d91-458b-a839-ad03662dfc34.aspx
>>>>
>>>>>Thanks a lot!!
>>>>>I had to comment several things on the source code, because I'm programming with VFP 6.0..
>>>>>
>>>>>There's still one problem.. When the program exceutes, the operating system shows an alert window indicating there's an application trying to send an email.., how can I overide this message?
>>>>>
>>>>>>Jonathan, we're using CDOS Sys with excellent results.
>>>>>>You don't need Third-party software, neither Outlook or any client installed.
>>>>>>Please check this great article:
>>>>>>
>>>>>>http://www.sweetpotatosoftware.com/SPSBlog/CommentView,guid,71acd54c-dcda-4dfa-b4ae-74854dd7947f.aspx
>>>>>>
>>>>>>
>>>>>>>Hi.
>>>>>>>I'm developing an application wich will run at night as a schedulled task in the server.. This application creates a log file with the results obtained. I would like to send an email with this file attached. Any suggestion?
>>>>>>>
>>>>>>>Thanks a lot in advance.
Previous
Reply
Map
View

Click here to load this message in the networking platform