Click here to Skip to main content
15,885,366 members
Home / Discussions / XML / XSL
   

XML / XSL

 
AnswerRe: XSL: how to properly reference to xml field? Pin
Richard Deeming17-Nov-14 2:52
mveRichard Deeming17-Nov-14 2:52 
GeneralRe: XSL: how to properly reference to xml field? Pin
Maciej Los17-Nov-14 4:25
mveMaciej Los17-Nov-14 4:25 
QuestionHow to get behavior similar to the obsoleted XmlValidatingReader Pin
John Whitmire30-Oct-14 3:53
professionalJohn Whitmire30-Oct-14 3:53 
AnswerRe: How to get behavior similar to the obsoleted XmlValidatingReader Pin
Gerry Schmitz30-Oct-14 21:21
mveGerry Schmitz30-Oct-14 21:21 
GeneralRe: How to get behavior similar to the obsoleted XmlValidatingReader Pin
John Whitmire3-Nov-14 3:04
professionalJohn Whitmire3-Nov-14 3:04 
SuggestionRe: How to get behavior similar to the obsoleted XmlValidatingReader Pin
John Whitmire6-Nov-14 2:47
professionalJohn Whitmire6-Nov-14 2:47 
QuestionVB.NET creat new XML Pin
Dereak12-Oct-14 17:43
Dereak12-Oct-14 17:43 
AnswerRe: VB.NET creat new XML Pin
User 41802545-Aug-15 2:28
User 41802545-Aug-15 2:28 
QuestionWriting XML from Excel Using VBA Pin
gedkins@deltagl.com30-Sep-14 14:15
gedkins@deltagl.com30-Sep-14 14:15 
AnswerRe: Writing XML from Excel Using VBA Pin
Richard Deeming1-Oct-14 1:45
mveRichard Deeming1-Oct-14 1:45 
Questiondelimiter or tokenizer in xslt Pin
DanielSatheesh27-Aug-14 1:22
DanielSatheesh27-Aug-14 1:22 
AnswerRe: delimiter or tokenizer in xslt Pin
George Jonsson13-Sep-14 23:55
professionalGeorge Jonsson13-Sep-14 23:55 
QuestionMultiple namespaces in xslt Pin
MaryJames7-May-14 22:00
MaryJames7-May-14 22:00 
AnswerRe: Multiple namespaces in xslt Pin
Richard MacCutchan7-May-14 22:24
mveRichard MacCutchan7-May-14 22:24 
GeneralRe: Multiple namespaces in xslt Pin
MaryJames8-May-14 3:16
MaryJames8-May-14 3:16 
GeneralRe: Multiple namespaces in xslt Pin
Richard MacCutchan8-May-14 3:19
mveRichard MacCutchan8-May-14 3:19 
QuestionUse XmlAttributeOverrides, but get an InvalidOperationException nevertheless Pin
Christian Treffler2-Apr-14 8:15
Christian Treffler2-Apr-14 8:15 
AnswerRe: Use XmlAttributeOverrides, but get an InvalidOperationException nevertheless Pin
Bernhard Hiller2-Apr-14 21:24
Bernhard Hiller2-Apr-14 21:24 
GeneralRe: Use XmlAttributeOverrides, but get an InvalidOperationException nevertheless Pin
Christian Treffler3-Apr-14 4:03
Christian Treffler3-Apr-14 4:03 
Hi Bernhard,

Bernhard Hiller wrote:
Did you add the [XmlInclude(typeof(CTrModules.MDataSaveXML))]
attribute to the base class

I don't really want to go with that option, because then I have to remember to add such an include for any class I derive from the base class.
But I tried it just for test purposes: I get the same problem.

The option I chose to use is this one:
Bernhard Hiller wrote:
or pass an array of types to the constructor of the serializer?

I wrote a method to gather all types in an array and I pass this array to the serializer.
I set a breakpoint at the call of the serializer and inspected this array:
-       Overrides   {System.Xml.Serialization.XmlAttributeOverrides}    System.Xml.Serialization.XmlAttributeOverrides
-       Non-Public members
-       types   Count = 5   System.Collections.Hashtable
-       [{CTrModules.MDataSaveXML}] {System.Collections.Hashtable}
+       Key {Name = "MDataSaveXML" FullName = "CTrModules.MDataSaveXML"}    object {System.RuntimeType}
-       Value   Count = 1   object {System.Collections.Hashtable}
+       ["Instance"]    {System.Xml.Serialization.XmlAttributes}
+       Raw View
-       [{CTrModules.QSM_Var_Dict}] {System.Collections.Hashtable}
+       Key {Name = "QSM_Var_Dict" FullName = "CTrModules.QSM_Var_Dict"}    object {System.RuntimeType}
-       Value   Count = 1   object {System.Collections.Hashtable}
+       ["Instance"]    {System.Xml.Serialization.XmlAttributes}
+       Raw View
-       [{System.String}]   {System.Collections.Hashtable}
+       Key {Name = "String" FullName = "System.String"}    object {System.RuntimeType}
-       Value   Count = 1   object {System.Collections.Hashtable}
+       ["Instance"]    {System.Xml.Serialization.XmlAttributes}
+       Raw View
-       [{CTrModules.MHandleException}] {System.Collections.Hashtable}
+       Key {Name = "MHandleException" FullName = "CTrModules.MHandleException"}    object {System.RuntimeType}
-       Value   Count = 1   object {System.Collections.Hashtable}
+       ["Instance"]    {System.Xml.Serialization.XmlAttributes}
+       Raw View
-       [{FFV_Cockpit.InternalExcHandler}]  {System.Collections.Hashtable}
+       Key {Name = "InternalExcHandler" FullName = "FFV_Cockpit.InternalExcHandler"}   object {System.RuntimeType}
-       Value   Count = 1   object {System.Collections.Hashtable}
+       ["Instance"]    {System.Xml.Serialization.XmlAttributes}

It contains all classes, including CTrModules.MDataSaveXML. All other classes can be serialized, but not this one.

CU,
Christian
QuestionXpath selecting nodes based on multiple attributes Pin
joost.versteegen4-Dec-13 4:28
joost.versteegen4-Dec-13 4:28 
AnswerRe: Xpath selecting nodes based on multiple attributes Pin
PIEBALDconsult4-Dec-13 4:46
mvePIEBALDconsult4-Dec-13 4:46 
GeneralRe: Xpath selecting nodes based on multiple attributes Pin
joost.versteegen4-Dec-13 20:50
joost.versteegen4-Dec-13 20:50 
AnswerRe: Xpath selecting nodes based on multiple attributes Pin
Richard Deeming4-Dec-13 4:57
mveRichard Deeming4-Dec-13 4:57 
QuestionXPath following-sibling Pin
savbace20-Oct-13 23:20
savbace20-Oct-13 23:20 
QuestionXML validation. Pin
Septimus Hedgehog18-Aug-13 22:02
Septimus Hedgehog18-Aug-13 22:02 

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.