mibuso.com

Microsoft Business Solutions online community
It is currently Mon May 20, 2013 3:12 am

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: WinHTTP, sending a XML-File
PostPosted: Tue Oct 06, 2009 11:16 am 
Offline

Joined: Tue Oct 06, 2009 11:10 am
Posts: 4
Location: Nürnberg
Country: Germany (de)
HI,

I am trying to send a XML-File through a HTTP-Port to a server.
I know that i can get a responsestream, but is there a way to do it the other way round?

My current Code:
Code: Select all
IF ISCLEAR(xmlDoc) THEN
  CREATE(xmlDoc);
xmlDoc.load(PathEx);

IF ISCLEAR(WinHttpReq) THEN
  CREATE(WinHttpReq);
WinHttpReq.Open('GET',VarHyperlink,FALSE);
WinHttpReq.SetRequestHeader('FileName','NAVISIONSYSTEMID_20091006_MAExport_Win.xml');
WinHttpReq.Send;
IF NOT WinHttpReq.WaitForResponse() THEN
  ERROR('Timed out');


Now I want to send the xmlDoc as Value for the argument "FileContent".


Top
 Profile E-mail WWW  
 
 Post subject: Re: WinHTTP, sending a XML-File
PostPosted: Tue Oct 06, 2009 3:20 pm 
Offline
MVP Microsoft Dynamics NAV

Joined: Wed Dec 15, 2004 6:11 pm
Posts: 8699
Location: 3rd rock from sun
Country: United States (us)
you need to change your code to


Code: Select all
WinHttpReq.Send(xmlDoc);

_________________
Rashed.

blog: http://mibuso.com/blogs/ara3n/


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: Google [Bot] and 9 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum


Search for:
Jump to: