Dear Friends,
I went through the examples provided with the Infragistics controls. They have all used the DATASETI urgently need UltraGrid examples using XML stream(data model) as input RATHER than the DATASET.I am not allowed to use the Dataset at all. I want a simple example that could use a Data Model at class modeland build a TWO-LEVEL hierarchy in the UltraGrid. Regards,Sid.
Sid,
The grid must have some sort of data source that it is bound to, and a DataSet provides an easy way to read in an XML file. If you can't use a DataSet, you need to use some other data structure that implements IList, ITypedList, or IBindingList (preferably IBindingList for full functionality). You could also use the UltraDataSource component.
-Matt
Dear Matt,I would be really obliged if you could help me with a short code sample as I am very new to IBindingList and UltraGrid control.Thanks and Regards,Siddharth
I'm not aware of any code samples that exist for loading an XML file into an IBindingList structure. Your best bet would be to use a BindingList<CustomClass> type for your list, where CustomClass has all of the properties/columns that exist in the XML file. I'm not sure why you need to take this approach, though, since you would have to parse the XML file yourself using custom logic; using a DataSet would save you a whole lot of trouble, as it has all the logic already in place to work seamlessly with the grid, and a simple method call to load from XML.