Jump to content
Software FX Community

3D Pie Chart Bugs


nabils

Recommended Posts

When I display a pie chart using the "Pie3" template from your samples with the below code (see Code 1) I get the same problem as the forum post titled "3D Pie edge disappears with certain values". The problem only happens when one item is added to the list.

Another problem I have is with labelling (see Code 2). The labels are positioned correctly on the chart with anything above 1 item in the list. For one item I get the below error (see error 1) and the label is displayed on the top left.

Are there any fixes available for these two bugs?

Thanks for your excellent support so far.

Error 1

 System.Windows.Data Error: 5 : Value produced by BindingExpression is not valid for target property.; Value='Infinity' BindingExpression:Path=X; DataItem='P' (HashCode=47980820); target element is 'ContentPresenter' (Name=''); target property is 'Left' (type 'Double')

System.Windows.Data Error: 5 : Value produced by BindingExpression is not valid for target property.; Value='Infinity' BindingExpression:Path=Y; DataItem='P' (HashCode=47980820); target element is 'ContentPresenter' (Name=''); target property is 'Top' (type 'Double')

 Code 1

  ChangeTemplate("Pie3");

  List<TestItem> values = new List<TestItem>();

  values.Add(new TestItem { Name = "Test", Value = 500 });

  chart1.ItemsSource = values;

Code 2

  <cfx:SeriesAttributes BindingPath="Value">

  <cfx:SeriesAttributes.PointLabel>

  <cfx:PointLabelAttributes Visibility="Visible">

  <cfx:PointLabelAttributes.Template>

  <DataTemplate>

  <Label Content="{Binding Path=DataItem.Name}" Background="Transparent" Foreground="Black" FontSize="8"/>

  </DataTemplate>

  </cfx:PointLabelAttributes.Template>

  </cfx:PointLabelAttributes>

  </cfx:SeriesAttributes.PointLabel>

  </cfx:SeriesAttributes>

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...