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.
Unfortunately, activation email could not send to your email. Please try again.

Keyboard arrow selection GridDataControl with only UnboundColumns

Thread ID:

Created:

Updated:

Platform:

Replies:

103247 Apr 16,2012 03:58 PM Apr 20,2012 07:16 AM WPF 1
loading
Tags: GridControl
Rich Fabros
Asked On April 16, 2012 03:58 PM

Hi,

I have a grid with unbound columns and an ItemsSource defined. Selection with the mouse is fine but Im having problems implementing the Keyboard arrow keys for selection.

It fires the recordsselectionchanged event but the GridDataControl.SelectedItems/GridDataControl.SelectedItem is always empty after selecting using the Keyboard Arrows. Even e.AddedItems for the RecordSelectionChanged event args is Empty.

I attached a sample of a grid close to my implementation.



Thanks,
Rich



GridKeyBoardArrowSelection_fb7c486d.zip

Rajasekar [Syncfusion]
Replied On April 20, 2012 07:16 AM

Hi Rich,

Sorry for the inconvenience, we are able to reproduce the issue and the fix for this issue will be available in our upcoming version 2012 Vol2 which will be out by first week of May.

Till that, you can use the below workaround,

gridDataControl1.CurrentCellActivated += new Syncfusion.Windows.ComponentModel.GridRoutedEventHandler(gridDataControl1_CurrentCellActivated);

void gridDataControl1_CurrentCellActivated(object sender, Syncfusion.Windows.ComponentModel.SyncfusionRoutedEventArgs args)
{
var item = (gridDataControl1.Model[this.gridDataControl1.Model.CurrencyManager.CurrentCell.RowIndex, this.gridDataControl1.Model.CurrencyManager.CurrentCell.ColumnIndex] as GridDataStyleInfo).CellIdentity.RecordEntry.Data as Models.Data;
selectedRow.Text = item.Number1.ToString();
}


Please let us know if you have any queries.

Thanks,
Rajasekar



CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;