Friday, January 14, 2011

DataTable from XML & data chema - Correct datatypes filling from xml

I have filled some datatables (datasets which contain 1 datatable) from xml.

//read xml / api into dataset..

DataSet ds = new DataSet();
ds.ReadXml("http://www.myuapi.com?request=KeyId=" + uuid);
MyRadGrid.DataSource = ds.Tables[0];

The problem is that all the data is looked at like string... some is really integer or doubles.. When we do filtering using Telerik filters... it needs to have the right datatype to filter properly...

SOLUTION: stay tuned...

I put the data into a linq query... and typed the items in the list... code to follow soon.

No comments:

Post a Comment