开发者

Typed DataSet merge issue

This is about C# typed dataSets

I have a typed dataset, I have used a partial class of the Row of the datatable and have added a new public int to it.

I can set that int, but when i call the Merge() to m开发者_运维问答erge a bunch of data together the added public int is lost (goes back to 0).

Anyone encountered this before?


I suppose you have added the new int-property to the Cs-sourcecode only.

if you edit the xsd-file that belongs to the dataset with visualstudio and add the int-field there (into the xsd) your dataset sould be regenerated and contain the new int-field as property. Merge(), GetXml() .. should work as expected. The new value is not automatically persisted into the database.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜