Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Passing long string error...
Message
From
06/03/2003 12:51:32
 
General information
Forum:
Visual FoxPro
Category:
Web Services
Miscellaneous
Thread ID:
00758813
Message ID:
00762289
Views:
14
>Thanks Michel. BTW do you know where I may find an article with samples on how to send soap messages with atachments ?

I'm not sure if there is a simpler way to do it but using SOAP low level, you can do it using this approach:
loConnector=CreateObject('MSSOAP.HttpConnector30')
loComposer=CreateObject('MSSOAP.DimeComposer30')
loSerializer=CreateObject('MSSOAP.SoapSerializer30')
loFileAttachment=CreateObject('MSSOAP.FileAttachment30')

loFileAttachment.FileName='d:\MyPicture.jpg'
loSerializer.InitWithComposer(loConnector.InputStream,loComposer)

loSerializer.StartEnvelope
loSerializer.StartBody

loSerializer.StartElement('Picture')
loSerializer.AddAttachmentAndReference(loFileAttachment)
loSerializer.EndElement

loSerializer.EndBody
loSerializer.EndEnvelope

loSerializer.Finished
This code is only a scenario on how you can accomplish it. It's not test and you would need to adjust things such as defining the loConnector properties and such.
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform