This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Getting Bad Response from Web service

 
Mamu Jan
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I'm trying to post to the web service http://www.webservicex.net/CurrencyConvertor.asmx?WSDL using SOAP.

My java program generates the following XML :



But I get the following response:



Can sum1 tell me wats wrong?? A detailed description of the service can be found here

Any sorta help wud be gr8ly appreciated.

Thanx
[ December 26, 2005: Message edited by: Mamu Jan ]
 
Jesus Angeles
Ranch Hand
Posts: 2068
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What value is in your html request for the header SOAPAction?

The link you provided showed an example with the text below

SOAPAction: "http://www.webserviceX.NET/ConversionRate"

Maybe you should do same.
 
Mamu Jan
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Jesus Angeles:
What value is in your html request for the header SOAPAction?

The link you provided showed an example with the text below

SOAPAction: "http://www.webserviceX.NET/ConversionRate"

Maybe you should do same.


When I used the above link I get an HTTP Error 404. Try opening the link in IE you'll get the same error.
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You're not supposed to access that URL, you should use it as value of the SOAPAction HTTP header as was suggested.
 
Mamu Jan
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Ulf Dittmer:
You're not supposed to access that URL, you should use it as value of the SOAPAction HTTP header as was suggested.


Plz can u show me how I can set a value for the SOAPAction HTTP header. I've never heard of SOAPAction b4

Thanx
 
Mamu Jan
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is the XML Message I need to generate :



and this is my code



I cudnt find any error in the code ?!! Can sum1 help me !
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can set HTTP headers like so:

MimeHeaders hd = message.getMimeHeaders();
hd.addHeader("SOAPAction", "http://www.webserviceX.NET/ConversionRate");
[ December 29, 2005: Message edited by: Ulf Dittmer ]
 
Mamu Jan
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanx every1 ! My program is working now !
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic