Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1070
Do I have to alter my data structure to use the XamDataChart?
posted

I would like to create a chart that looks similar to the ColumnSeries example found at this link.

http://help.infragistics.com/Help/NetAdvantage/WPF/2012.2/CLR4.0/html/xamDataChart_Category_Bar_Series.html

The problem is that I don’t think my data is in the correct structure, but before I change the data structure or try to create some kind of data adapter I wanted to ask the forum. I have a web service that returns data in a format similar to the table below. The idea is similar to an index, where the user is searching for something and the web service will return how many records (COUNT) were found in which table (DATASET). There is a DATASET column/property that contains values of table name where data was found.

DATE

DATASET

COUNT

Monday

Table1

10

Monday

Table2

20

Monday

Table3

30

 

 

 

...but I think the data needs to be in this format for the XamDataChart to work like the ColumnSeries.

DATE

TABLE1

TABLE2

TABLE3

Monday

10

20

30

 

 

 

 

 

 

 

 

 

 

 

 

I don’t think we can get the web service to return columns/properties that are the names of the tables. If the data has to be in this format to get the chart to display correctly then my only choice is to create some kind of adapter that alters the structure. I was thinking of using a System.Data.DataTable or an ObservableCollection of dynamic .NET objects using DynamicObject or ExpandoObject in the System.Dynamic namespace. I figure I need something like to this to create object properties on the fly.

So my question is can I display my data using the XamDataChart like its shown in the example or do I have to alter my data into a format that the XamDataChart can use?

Thanks,

   -eric

 

Parents
No Data
Reply Children
No Data