| . | ![]() |
|
|
Using OLE Servers in Visual FoxPro Discussion Visual FoxPro (v3.0 min) interfaces to OLE Servers in a similar manner to Visual Basic, but with slightly different syntax. Since many OLE Server examples are presented in Visual Basic, let's focus on the syntactical differences between the two. We will then be able to easily translate VB examples into Visual FoxPro syntax in the future. As an example, two sets of code are shown below. Each one creates and sends an E-mail message through the IDSMail OLE Server: Visual Basic v3.0 Syntax Dim idsMail as Object
Set idsMail = CreateObject("IDSMailInterface.Server")
idsMail.ObjectKey = "ABCDE12345"
idsMail.AddRecipientTo "Jim Stevens"
idsMail.AddRecipientCc "Mary Brown, Doug Williams"
idsMail.Subject = "Meeting Agenda"
idsMail.AddAttachment "C:\MEETINGS\AGENDA.DOC"
idsMail.Message = "Here is the agenda for this weeks meeting."
idsMail.Send
Local idsMail
idsMail = CreateObject("IDSMailInterface.Server")
idsMail.ObjectKey = "ABC123"
idsMail.AddRecipientTo ("Jim Stevens")
idsMail.AddRecipientCc ("Mary Brown, Doug Williams")
idsMail.AddAttachment ("C:\MEETINGS\AGENDA.DOC")
idsMail.Subject = "Meeting Agenda"
idsMail.Message = "Here is the agenda for the weekly meeting."
idsMail.Send
|
© 1993-2004, AssurX, Inc. All Rights Reserved. Trademarks. 408-778-1376 | email: info@intuitive-data.com |
|