Hi,
I would like to know if I can to make a dynamically binding behind code for to apply the color of columns in xamdatachart from a property in datasource with the color that it must show.
Thank you.
Hello David,
I am just checking the progress of this issue and was wondering if you managed to achieve your goal or if you need any further assistance on the matter.
Hello Stefan,
Thank you, but with this example we don't make working properly with infragistics 14.x version, this example works fine with 12.x versions.
We trying to make a binding with BrushProperty in Columnseries object, but it doesn't work, I attach a little example:
Simple Class with values
public class SimpleData
{
public Brush Color{ get; set; }
public Double Value { get; set; }
}
Making ColumnSerie
private ColumnSeries BuildColumnSerie(CategoryXAxis axisX, NumericYAxis axisY, ObservableCollection<SimpleData> dataSource)
ColumnSeries serie = new ColumnSeries();
serie.XAxis = axisX;
serie.YAxis = axisY;
serie.MarkerType = MarkerType.Circle;
serie.ItemsSource = dataSource;
serie.ValueMemberPath = "Value";
serie.SetBinding(ColumnSeries.BrushProperty, new Binding("Color"));
...
In the ObservableCollection<SimpleData>dataSource for each value we have a different color and value configurated in their properties, the binding with the values works correctly but the binding with the Color property it doesn't work, I assume that the used path for color binding is incorrect,
I appreciate if you can help me.