Lakshmi,
Thanks for the sample.
I should have mentioned that the Xam.Forms project is in c#, not XAML.
I've got an existing app running with medical data on charts and the trackball all working.
If I try :-
lineSeries1.TrackballLabelTemplate = new DataTemplate(() =>
{
var lblData = new Label() { Text = "Hello" };
return new ViewCell { View = lblData };
});
expecting the DataTemplate to fire as required (similar to ListView DataTemplate), it never does.
The built in data label always displays, never the one from the DataTemplate.
Is there anything else I'm missing in the Trackball line to get the data template working?
Current code looks like :-
var trackballBehavior = new ChartTrackballBehavior();
trackballBehavior.ShowLabel = true;
trackballBehavior.ShowLine = true;
trackballBehavior.LineStyle.StrokeDashArray = new double[2] { 2, 3 };
chart.ChartBehaviors.Add(trackballBehavior);
Regards,
Ian