I have a problem deserealizating a xml string ... no bugs but each property
value is not assigned..
Anyone knows why?
This is my code..
public static object deserealizarObjeto(string _objectoSerializado,
Type _tipo)
{
try
{
// Deserializamos el objeto
string _nombreObjeto = getNombreObjeto(_tipo);
XmlSerializer serializer = new XmlSerializer(_tipo,
"http://tempuri.org/" + _nombreObjeto + ".xsd");
byte[] _bytes = Encoding.UTF8.GetBytes(_objectoSerializado);
MemoryStream _ms = new MemoryStream(_bytes);
//XmlReader reader = new XmlTextReader(_ms);
object _obj = serializer.Deserialize(_ms);
_ms.Close();
return _obj;
}
catch (Exception ex)
{
throw ex;
}
}
thanks in advanced
--
View this message in context:
http://mono-for-android.1047100.n5.nabble.com/memory-stream-way-deserialize-tp5711727.html
Sent from the Mono for Android mailing list archive at Nabble.com.
_______________________________________________
Monodroid mailing list
[email protected]
UNSUBSCRIBE INFORMATION:
http://lists.ximian.com/mailman/listinfo/monodroid