Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Sending a parameter to webservice with MSXML2.ServerXMLHTTP?

Reply
Thread Tools

Sending a parameter to webservice with MSXML2.ServerXMLHTTP?

 
 
Michael Christensen
Guest
Posts: n/a
 
      10-24-2005
Hi

How do I send an input-param to my web service with
MSXML2.ServerXMLHTTP?

Can this be done without the soap-toolkit?
Can't find anything about it - looking forward getting some help
-------------
Function GetLatest()
Dim url, xmlhttp, XMLDOM, XMLNode

url = "http://www.mssoapinterop.org/asmx/simple.asmx/echoString"
Set xmlhttp = Server.CreateObject("MSXML2.ServerXMLHTTP")
Call xmlhttp.Open("POST", url,False)
Call xmlhttp.send

'Parse result
Set XMLDOM = Server.CreateObject("Microsoft.XMLDOM")
XMLDOM.Load(xmlhttp.responseBody)
Set XMLNode = XMLDOM.SelectSingleNode("//string")

If Not XMLNode Is Nothing Then
GetLatest = XMLNode.text
End If
End Function
-------------

Best regards

Michael Christensen

 
Reply With Quote
 
 
 
 
Steven Burn
Guest
Posts: n/a
 
      10-24-2005
Call() is not necessary .....

sParams = "&some=param"
xmlhttp.Open "POST", url,False
xmlhttp.send sParams

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

"Michael Christensen" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) oups.com...
> Hi
>
> How do I send an input-param to my web service with
> MSXML2.ServerXMLHTTP?
>
> Can this be done without the soap-toolkit?
> Can't find anything about it - looking forward getting some help
> -------------
> Function GetLatest()
> Dim url, xmlhttp, XMLDOM, XMLNode
>
> url = "http://www.mssoapinterop.org/asmx/simple.asmx/echoString"
> Set xmlhttp = Server.CreateObject("MSXML2.ServerXMLHTTP")
> Call xmlhttp.Open("POST", url,False)
> Call xmlhttp.send
>
> 'Parse result
> Set XMLDOM = Server.CreateObject("Microsoft.XMLDOM")
> XMLDOM.Load(xmlhttp.responseBody)
> Set XMLNode = XMLDOM.SelectSingleNode("//string")
>
> If Not XMLNode Is Nothing Then
> GetLatest = XMLNode.text
> End If
> End Function
> -------------
>
> Best regards
>
> Michael Christensen
>



 
Reply With Quote
 
 
 
 
Bob Barrows [MVP]
Guest
Posts: n/a
 
      10-24-2005
Michael Christensen wrote:
> Hi
>
> How do I send an input-param to my web service with
> MSXML2.ServerXMLHTTP?
>
> Can this be done without the soap-toolkit?.


Not that I know of. I've posted some links to relevant articles in the past.
I seem to recall 4GuysFromRolla had some good articles about it, so you may
want to concentrate your google search on their site. IIRC, searching for
"consume web service from classic asp" (no quotes) will give you some
relevant links.



--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem to call a WEBSERVICE in another WEBSERVICE (AXIS/ TOMCAT) Cyril Java 2 06-01-2006 06:07 PM
Problem! webservice.htc calling nonsecure webservice from a secured ssl https webpage batista ASP .Net 1 01-26-2006 12:05 PM
Problem! webservice.htc calling nonsecure webservice from a secured ssl https webpage batista ASP .Net 0 01-26-2006 08:13 AM
WebService on Java server versus WebService on .NET Mr. x Java 2 10-09-2003 11:21 PM
use another webservice in a webservice Mr. x ASP .Net Web Services 0 09-26-2003 10:59 PM



Advertisments