Hi,
I have an eventhandler for the GraphicalViewItemFormatting event so I can change the look&feel of the items in the ganttview according to the contents. Now I also want to make it more clear which item is selected. Unfortunately I seem to be doing something wrong.
In the handler I have this part that should draw the border in red:
private void GanttViewElement_GraphicalViewItemFormatting(object sender, Telerik.WinControls.UI.GanttViewGraphicalViewItemFormattingEventArgs e)
{
if (e.ItemElement.Selected)
{
e.ItemElement.TaskElement.BorderColor = Color.Red;
e.ItemElement.TaskElement.BorderBoxStyle = Telerik.WinControls.BorderBoxStyle.FourBorders;
e.ItemElement.TaskElement.BorderWidth = 6;
e.ItemElement.TaskElement.BorderDashStyle = System.Drawing.Drawing2D.DashStyle.Solid;
e.ItemElement.TaskElement.DrawBorder = true;
}
}
But the border keeps working in the standard way. There is only a slight difference between selected and non-selected items.
What part am I missing?