Skip to main content
GameDev.net gamedev.net
🔒 Locked

C# - XmlSerializer and Type.FullName

Started by dave Apr 17, 2010 at 4:33 AM 0 replies 1.2k views
Original Post
dave
dave
If i am serializing out an arbitrary collection of objects using XmlSerializer, how do i create an object of the serialized type to deserialize in to? A simple example being that XmlSerializer outputs the short name ("String" not "System.String") to the XML so when i am reading the XML i can't simply do Type.GetType(Reader.Name) to get the type to use with Activator. I essentially need to resolve this shortened name into the full name or have the serialize write out the full name so i can reconstruct the type. Any ideas?

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.