HA
haneefm
Syncfusion Team
April 9, 2007 09:33 AM UTC
Hi Steve,
You should call the Refresh() method before calling ScrollCellInView method and should turn ON the pixel scrolling of the grid by setting XScrollPixel to true. Please try the suggestion and let me know if this helps.
this._gridControl.VScrollPixel = true;
this._gridControl.HScrollPixel = true;
if ( _lastHilite != oldHilite ) // hilite changed
{
GridRangeInfo test= GridRangeInfo.Cell(_lastHilite.X, _lastHilite.Y);
GridRangeInfo gri = this._gridControl.ViewLayout.VisibleCellsRange;
bool visible = gri.Contains ( test );
this._gridControl.Refresh(); // force a repaint
if ( ! visible )
{
this._gridControl.ScrollCellInView ( test );
}
}
Best regards,
Haneef