Quantcast
Channel: XML, System.Xml, MSXML and XmlLite forum
Viewing all articles
Browse latest Browse all 935

XmlSerializer constructors and pre-generated serializers

$
0
0
Hi,
 
I have a pre-generated serializer assembly loaded in the GAC.

When I have

XmlSerializer serializer = new XmlSerializer(typeof("myType"));
Then the pre-generated assembly is loaded and used.

However, if I have:
string namespace = myNameSpace;
XmlSerializer serializer = new XmlSerializer(typeof("myType"), namespace);


OR

XmlRootAttribute root = myXmlRoot;


XmlSerializer serializer = new XmlSerializer(typeof("myType"), root);

Then .net is generating temporary assemblies and not loading the one I have in the GAC.


Is there a way to use these overloaded XmlSerializer constructors and force .net to use the existing serializer assembly from the GAC?

Thanks!

Viewing all articles
Browse latest Browse all 935

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>