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
4028
"Invalid data source" error when changing DataSource
posted

I am using a chart (column chart) to show variable data. That is, the user selects the critiera they wish to chart, then press a button, and the data is generated and displayed on the chart. They then repeat this process till their hearts content.

This all works fine, so long as the chart is not visible (on a tab which is not visible). But if it is, I get the error:

Invalid data source, this type is unsupported data type. Supported data types accepted as valid data source are DataTable, DataView, DataSet, Array and IList

I am binding the chart to a datatable. Roughly, the code I'm using is:

dt = new DataTable();
// Generate dt data
ultraChart1.DataSource = dt;
ultraChart1.DataBind();

What am I doing wrong here? How can I load new data while the user is viewing the chart?