Click here to Skip to main content
15,039,359 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
In Javascript I am using Sys.Serialization.JavaScriptSerializer to Serialize or Deserialize the object.

I found, if I already pass a deserializedObject to Sys.Serialization.JavaScriptSerializer.Deserialize method, an excpetion is raised like 'object cannot deserialize', because object is already deserialized.
So, I need to check whether an object is serialized or not before passing it to Deserialize function.

Please let me know, if my question is not clear
Posted
Updated 27-Dec-10 21:59pm
v3

1 solution

if ( typeof obj == "string" )
{
//u already serializer the obj,u can pass it to deserialize function.
}
   

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900