We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Cant arrow-key scroll up to first row that is disabled

I have a virtual grid that has various rows with Enabled = False. This works great, making arrow key navigation SKIP OVER those disabled cells. However, when I use the arrow keys (or page up/down) to scroll down a few pages, then come all the way up to the top of the grid, the first row never scrolls into view. Since it''s disabled, the activecell can''t be set to that top row, so the grid doesn''t scroll. Any way to get the grid to scroll up to the top row, while still keeping the row disabled? (I''ve tried making the top row ReadOnly instead of disabled, but then the text in that row is selectable...not editable, but selectable - looks bad) I''ve posted a simple example app that shows this behavior. Thanks! keyboardscrollgrid_9588.zip

2 Replies

AD Administrator Syncfusion Team August 25, 2004 03:39 PM UTC

You can try handling QueryNextCurrentCellPosition.
private void grid1_QueryNextCurrentCellPosition(object sender, GridQueryNextCurrentCellPositionEventArgs e)
	if(e.RowIndex == 1 && this.grid1.TopRowIndex != 1)
		this.grid1.TopRowIndex = 1;

DA Dan August 25, 2004 05:28 PM UTC

Thanks Clay - that works great!

Live Chat Icon For mobile
Up arrow icon