AD
Administrator
Syncfusion Team
September 16, 2005 02:09 PM UTC
Hi Franz,
You could handle the PrepareViewStyleInfo to do this.
this.ListBox1.Grid.AlphaBlendSelectionColor = Color.FromArgb(1,0,0,0);
this.ListBox1.Grid.PrepareViewStyleInfo +=new GridPrepareViewStyleInfoEventHandler(Grid_PrepareViewStyleInfo);
private void Grid_PrepareViewStyleInfo(object sender, GridPrepareViewStyleInfoEventArgs e)
{
if(e.ColIndex > 0 && e.RowIndex > 0)
{
GridRangeInfoList rangeList;
if(this.ListBox1.Grid.Selections.GetSelectedRanges(out rangeList, false)
&& rangeList.AnyRangeIntersects(GridRangeInfo.Cell(e.RowIndex, e.ColIndex)))
{
e.Style.BackColor = Color.DarkBlue;
e.Style.TextColor = Color.White;
}
}
}
Best regards,
Jay N
AD
Administrator
Syncfusion Team
September 19, 2005 06:06 AM UTC
Thanks Jay, that works great.