Click here to Skip to main content
15,867,704 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
GeneralRe: how to add module in c#.net Pin
sarayumadhavan21-Nov-05 1:01
sarayumadhavan21-Nov-05 1:01 
QuestionMassive UI updating & perfomance Pin
David Menéndez Cisterna8-Nov-05 9:11
David Menéndez Cisterna8-Nov-05 9:11 
AnswerRe: Massive UI updating & perfomance Pin
[Marc]8-Nov-05 11:40
[Marc]8-Nov-05 11:40 
GeneralRe: Massive UI updating & perfomance Pin
David Menéndez Cisterna8-Nov-05 23:58
David Menéndez Cisterna8-Nov-05 23:58 
Questionsetup project with Visual Studio .NET 2003 Pin
madretierra8-Nov-05 6:34
madretierra8-Nov-05 6:34 
AnswerRe: setup project with Visual Studio .NET 2003 Pin
rwestgraham9-Nov-05 10:16
rwestgraham9-Nov-05 10:16 
GeneralRe: setup project with Visual Studio .NET 2003 Pin
madretierra9-Nov-05 22:55
madretierra9-Nov-05 22:55 
QuestionSystem.Xml.Serialization - deserializing xml to types created in dynamic assembly Pin
Rein_Petersen8-Nov-05 5:56
Rein_Petersen8-Nov-05 5:56 
Hi All,

I've been working on a saved dynamic assembly that holds all the types and corresponding xml serialization attributes I need to deserialize xml documents into objects.

You might wonder why I would choose a dynamic assembly over simply coding the types at compile time - the simple answer is I don't know what the types will be before hand and I only have an xml schema (from which I build the dynamic assembly) with various attributes that change frequently.

Since the schema only defines data types (methods,events,delegates could probably be defined within xs:appinfo tags but in my case they are not), I needed a way to add functionality to these dynamically created classes which were otherwise, nothing more than just data stubs.

The method I chose was to define (at compile-time) abstract base classes from which classes in my dynamic assembly could inherit. Now these simple data-stub classes had a complement of methods to enable them to do more than simply hold data in fields.

Unfortunately, it seems that since my dynamic classes now inherit from classes defined at compile-time, the xml serializer gets confused (see error and stack trace below).

It worked fine before I added the inheritance - maybe I need a reference (somehow) to the hardcoded assembly containing the types I inherit from in my dynamic assembly.

Any suggestions? Thanks in advance, Rein

[[error and stack trace]]

"An unhandled exception of type 'SystemIO.FileNotFoundException' occurred in mscorlib.dll.

Addtional Information: File or assembly name [xxxxx.dll], or one of it's dependencies, was not found."

stack trace:

at System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Boolean isStringized, Evidence assemblySecurity, Boolean throwOnFileNotFound, Assembly locationHint, StackCrawlMark& stackMark)

at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Boolean stringized, Evidence assemblySecurity, StackCrawlMark& stackMark)

at System.Reflection.Assembly.Load(AssemblyName assemblyRef, Evidence assemblySecurity)

at System.CodeDom.Compiler.CompilerResults.get_CompiledAssembly()

at System.CodeDom.Compiler.CompilerResults.get_CompiledAssembly()

at System.Xml.Serialization.Compiler.Compile()

at System.Xml.Serialization.TempAssembly..ctor(XmlMapping[] xmlMappings)

at System.Xml.Serialization.XmlSerializer.GenerateTempAssembly(XmlTypeMapping xmlTypeMapping)

at System.Xml.Serialization.XmlSerializer..ctor(Type type, String defaultNamespace)

at System.Xml.Serialization.XmlSerializer..ctor(Type type)
AnswerRe: System.Xml.Serialization - deserializing xml to types created in dynamic assembly Pin
leppie12-Nov-05 12:58
leppie12-Nov-05 12:58 
QuestionFor native clients to receive notifications from remoting callback interfaces... Pin
chervu8-Nov-05 4:06
chervu8-Nov-05 4:06 
AnswerRe: For native clients to receive notifications from remoting callback interfaces... Pin
S. Senthil Kumar8-Nov-05 4:38
S. Senthil Kumar8-Nov-05 4:38 
GeneralRe: For native clients to receive notifications from remoting callback interfaces... Pin
chervu8-Nov-05 6:18
chervu8-Nov-05 6:18 
GeneralRe: For native clients to receive notifications from remoting callback interfaces... Pin
S. Senthil Kumar8-Nov-05 21:45
S. Senthil Kumar8-Nov-05 21:45 
QuestionRefreshing all instances of a class on a queued message Pin
jlraffin8-Nov-05 0:43
jlraffin8-Nov-05 0:43 
AnswerRe: Refreshing all instances of a class on a queued message Pin
jlraffin8-Nov-05 4:53
jlraffin8-Nov-05 4:53 
QuestionDoesn't a Process have a user? Pin
Dave Midgley8-Nov-05 0:42
Dave Midgley8-Nov-05 0:42 
AnswerRe: Doesn't a Process have a user? Pin
S. Senthil Kumar8-Nov-05 5:12
S. Senthil Kumar8-Nov-05 5:12 
GeneralRe: Doesn't a Process have a user? Pin
Dave Midgley8-Nov-05 5:30
Dave Midgley8-Nov-05 5:30 
QuestionProblem using RSAPKCS1SignatureFormatter in Framework 1.1 Pin
dhanashekar7-Nov-05 19:44
dhanashekar7-Nov-05 19:44 
QuestionWPF(Avalon) Pin
1nsp1r3d7-Nov-05 6:42
1nsp1r3d7-Nov-05 6:42 
QuestionAccessing control from another file Pin
Eran6-Nov-05 22:49
Eran6-Nov-05 22:49 
QuestionVS.NET 2005 & VS.NET 2003 - can they co-exist safely? Pin
code_wiz5-Nov-05 9:59
code_wiz5-Nov-05 9:59 
AnswerRe: VS.NET 2005 & VS.NET 2003 - can they co-exist safely? Pin
Kevin McFarlane6-Nov-05 4:32
Kevin McFarlane6-Nov-05 4:32 
QuestionImplementing developers API, a question about access control... Pin
Member 965-Nov-05 5:57
Member 965-Nov-05 5:57 
QuestionTrain free @Microsoft Pin
vikas amin4-Nov-05 22:57
vikas amin4-Nov-05 22:57 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.