locked
only two first node of my XML file is deserialised. RRS feed

  • Question

  • User-748049670 posted

    Hi,

    I deserialize an xml file  like this 

     public static T DeSerializeObj<T>(this string xmlFullFileName)
            {
                System.Diagnostics.Contracts.Contract.Requires<ArgumentNullException>(!string.IsNullOrEmpty(xmlFullFileName));
                var xmlSerializer = new XmlSerializer(typeof(T));
                
                var streamReader = new StreamReader(xmlFullFileName);
                var configurationHeaderForm = (T)xmlSerializer.Deserialize(streamReader);
                streamReader.Close();
                return configurationHeaderForm;
            }

    But only two first node of my XML file is deserialised.

    How to deserialise all file ?

    Best regards

    Friday, June 12, 2015 11:41 AM

All replies