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
1060
Legend is hiding in XamDataChart.
posted

Hi,

I am trying to create a simple xamDataChart with Legend box, but legend box is not completely visible.  

And here is my XAML code for chart definition.

<ig:XamDataChart Grid.RowSpan="2" HorizontalAlignment="Stretch" Margin="0" Name="theChart" Background="#EBF3FB" VerticalAlignment="Stretch" Grid.Column="0" Grid.Row="1">
                    <ig:XamDataChart.Axes>
                        <ig:CategoryXAxis x:Name="xmXAxis" ItemsSource="{Binding}" Label="{}{X}" Stroke="Transparent" MajorStroke="Transparent">
                            <ig:CategoryXAxis.LabelSettings>
                                <ig:AxisLabelSettings Location="OutsideBottom" Extent="35" Visibility="Visible" />
                            </ig:CategoryXAxis.LabelSettings>
                        </ig:CategoryXAxis>
                        <ig:NumericYAxis x:Name="xmYAxisPrice" MajorStroke="Transparent" MinorStroke="Transparent">
                            <ig:NumericYAxis.LabelSettings>
                                <ig:AxisLabelSettings Location="OutsideLeft" Extent="55" Visibility="Visible" />
                            </ig:NumericYAxis.LabelSettings>
                        </ig:NumericYAxis>
                    </ig:XamDataChart.Axes>
                    <ig:XamDataChart.Series>
                        <ig:LineSeries Thickness="2" ItemsSource="{Binding}" Brush="Blue" UnknownValuePlotting="LinearInterpolate" ValueMemberPath="Y1" XAxis="{Binding ElementName=xmXAxis}" YAxis="{Binding ElementName=xmYAxisPrice}" Title="ABC" Legend="{Binding ElementName=MyLegendItem}" />
                    </ig:XamDataChart.Series>
                </ig:XamDataChart>
                <ig:Legend x:Name="MyLegendItem" HorizontalAlignment="Right" VerticalAlignment="Top" Width="200" Height="100" Content="Legend"></ig:Legend>

I don't know what I am doing wrong here. Kindly help.