开发者

loading datatable from xml schema

开发者 https://www.devze.com 2023-01-15 22:01 出处:网络
I m trying loading data table from xml schema. I can see column names on datatable but, i cant see datas. here is my code:

I m trying loading data table from xml schema. I can see column names on datatable but, i cant see datas. here is my code:

   StringReader sr = new StringReader(dsSorgu.Tables[0].Rows[i]["sorguSonucu"].ToString());
   s.M_Sonucu = new DataTable();
   s.M_Sonucu.ReadXml开发者_如何学运维Schema(sr);
   srgKullaniciSorgulari.Add(s);

sr contains xml schema.


An xml schema doe not contain any data, just table, relation, and constraint definitions. You will need to call the ReadXml method to load the actual data (which will be validated by your schema).


"An XML Schema describes the structure of an XML document."

http://www.w3schools.com/schema/default.asp

If it is a schema it should not have data in it. You need another file with the data in it and the schema can be used to validate that file if necessary.

http://www.w3schools.com/schema/schema_intro.asp See: What is an XML Schema?

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号