title: How to invoke a web service call using vbscript
body: <p>i am beginner in coding.</p>
  
  <p>I have to call a web service below:
  <a href="http://www.w3schools.com/webservices/tempconvert.asmx?op=CelsiusToFahrenheit" rel="nofollow">http://www.w3schools.com/webservices/tempconvert.asmx?op=CelsiusToFahrenheit</a></p>
  
  <p>enter a value like 25 and click Invoke returns you the temperature in Fahrenheit.</p>
  
  <p>For that i used below code:</p>
  
  <pre><code>url = "http://www.w3schools.com/webservices/tempconvert.asmx?op=CelsiusToFahrenheit&amp;Celsius=25"
  'Set oHttpReq = CreateObject("Microsoft.XMLHTTP") 'when i use XMLHTTP i am getting error saying "The download of the specified resource has failed."
  
  Set oHttpReq = CreateObject("MSXML2.ServerXMLHTTP") 'If i use it, the response contains Root Element missing
  
  oHttpReq.open "POST", url, False
  oHttpReq.send
  
  'Response
  responseText = oHttpReq.responseText 
  
  WScript.echo responseText
  </code></pre>
  
  <p>Can anyone help me?</p>