[quoted text, click to view] "Eric Peterson" <EricPeterson@discussions.microsoft.com> wrote in message
news:527C3273-BC2C-428E-B8B6-A22C07936B82@microsoft.com...
> When I debug my application, or any application that uses the DLL that
> uses
> System.XML.Serialization.XmlSerializer, I receive the following
> exception...
> When running the compiled code, no exception and the code works fine. Of
> course, if i turn BindingFailure Exceptions off in VS Debugging, it does
> not
> show the error.
>
> BindingFailure was detected
> Message: The assembly with display name 'MyDLL.XmlSerializers' failed to
> load in the 'LoadFrom' binding context of the AppDomain with ID 1.
> The cause of the failure was: System.IO.FileNotFoundException: Could not
> load file or assembly 'MyDLL.XmlSerializers,
> Version=1.0.2761.24591, Culture=neutral, PublicKeyToken=d2591aaacdc55154'
> or
> one of its dependencies. The system cannot find the file specified. File
> name: 'MyDLL.XmlSerializers, Version=1.0.2761.24591, Culture=neutral,
> PublicKeyToken=d2591aaacdc55154'
>
> System.XML is referenced in the MyDLL project. What I don't understand is
> why is it trying to load MyDLL.XmlSerializers when
> System.XML.Serialization.XmlSerializers is implicitly referenced?
MyDLL.XmlSerializers would be an automatically generated assembly containing
compiled XML Serialization code specific to your classes. This is so that
these classes don't have to be generated and compiled the first time they're
used. It also allows the serializers to be placed in the GAC and used in
different applications.
--
John Saunders [MVP]