function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
hramanihramani 

Web service error

System.CalloutException: Web service callout failed: Failed to deserialize value '8/24/2011', due to:Unable to parse date

 

Pls help. Its very urgent

mauro_offermannmauro_offermann

This error occurs when you try to convert a field salesforce date String to Date and the date format is not understood by salesforce.
When invoking a webservice everything is serialized as a String in the SOAP XML response traveling.
In the particular case of his mistake the webservice is sending the date 8/24/2011 and in a field that is of type date salesforce and that format is not understood.

Sometimes that occurs when changes are made to the data types after the service client generation.

Some tips solution:
* Try to identify the field that is sending the date 8/24/2011
* Check that the type of data in salesforce is the same you are sending your WS.
* If you can handle the format of return on your WS, change to understood by salesforce.
* If you can not change the format of return on that field in the WS, try converting a String and refresh your WS client.

hramanihramani

Thanku so much :)