private void Highlight(UIElement elt)
{
if (elt is Shape) // PieChart, LineChart
{
origColor = (elt as Shape).Fill;
(elt as Shape).Fill = highlightColor;
}
else if (elt is Border) // BarChart, ColumnChart
{
origColor = (elt as Border).Background;
(elt as Border).Background = highlightColor;
}
highlightedChartPiece = elt;
}