Bug 8491 - DataTable.ReadXml don't restore ExtendedProperties
Summary: DataTable.ReadXml don't restore ExtendedProperties
Status: NEW
Alias: None
Product: Class Libraries
Classification: Mono
Component: System.Data (show other bugs)
Version: 2.10.x
Hardware: PC All
: --- normal
Target Milestone: Untriaged
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2012-11-19 02:54 UTC by sfrolov
Modified: 2012-11-19 02:56 UTC (History)
1 user (show)

See Also:
Tags: DataTable;ExtendedProperties
Is this bug a regression?: ---
Last known good build:


Attachments
XML generated by sample code (929 bytes, text/xml)
2012-11-19 02:54 UTC, sfrolov
Details

Description sfrolov 2012-11-19 02:54:35 UTC
Created attachment 2962 [details]
XML generated by sample code

DataTable.ReadXml don't restore values from DataTable.ExtendedProperties, although they are in the xml.

Code to reproduce:
<code>
    DataTable table1 = new DataTable("Test");
    table1.Columns.Add("ID", typeof(long));
    table1.Columns.Add("NAME", typeof(string));
    table1.ExtendedProperties.Add("DATE", DateTime.Now);
    table1.Rows.Add(1, "row1");
    Console.WriteLine("table1.ExtendedProperties.Count={0}", table1.ExtendedProperties.Count);
    table1.WriteXml("test.xml", XmlWriteMode.WriteSchema);

    DataTable table2 = new DataTable();
    table2.ReadXml("test.xml");
    Console.WriteLine("table2.ExtendedProperties.Count={0}", table2.ExtendedProperties.Count);
</code>

Note You need to log in before you can comment on or make changes to this bug.