mardi 24 février 2015

Windows Forms chart and databinding

I'm trying to create a databinding for a chart on Windows Forms. This is my code:



ch.Series["Dep"].Points.DataBindXY(data, "Date", data, "Value");
ch.DataBind();


Data is of type DataBinding. The issue is that whenever I modify the DataSource:



data.DataSource = ... (list)


The chart doesn't get updated. Actually this same approach works perfectly with widgets like comboboxes (as soon as I update DataBinding.DataSource the widget is updated).


I even tried calling Update() or Refresh() with no results. What am I missing?


Aucun commentaire:

Enregistrer un commentaire