Hi, I would like to enquire on an issue as per title. For other telerik controls like RadGridView, I can disable tabbing within the cells with IsTabStop = false. But this doesn't work for RadSpreadSheet. I've tried Focusable=false on it and IsTabStop = false on application level as well, but to no avail.
3 Answers, 1 is accepted
0
Hello,
What you can do to achieve this result is to replace the key binding which is responsible for tabbing with an empty one. The following code snippet contains an example of how this can be done.
I hope this helps.
Regards,
Anna
Telerik
What you can do to achieve this result is to replace the key binding which is responsible for tabbing with an empty one. The following code snippet contains an example of how this can be done.
DelegateCommand emptyDelegateCommand =
new
DelegateCommand((parameter) => { });
this
.radSpreadsheet.ActiveWorksheetEditor.KeyBindings.RegisterCommand(emptyDelegateCommand, Key.Tab, ModifierKeys.None);
this
.radSpreadsheet.ActiveWorksheetEditor.KeyBindings.RegisterCommand(emptyDelegateCommand, Key.Tab, ModifierKeys.Shift);
I hope this helps.
Regards,
Anna
Telerik
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
0
Dexter
Top achievements
Rank 1
answered on 24 Sep 2014, 12:38 AM
Hi Anna, thanks for your assistance. I'm getting a null reference exception though when trying to set it after InitializeComponents();
Setting it to a button works, but I need this to go in effect right after loading the application.
This is my codes currently:
I also tried setting it outside, with no avail:
Setting it to a button works, but I need this to go in effect right after loading the application.
This is my codes currently:
webClient.OpenReadCompleted += (senders, eventArgs) =>
{
var formatProvider = new XlsxFormatProvider();
sheet1211.Workbook = formatProvider.Import(eventArgs.Result);
foreach (Worksheet worksheet in sheet1211.Workbook.Worksheets)
{
worksheets.Add(worksheet);
}
PrepareWorksheet(currWSIndex);
sheet1211.ActiveWorksheet = worksheets[0]; //this line is not needed, just testing if this helps, but it didn't
var emptyDelegateCommand = new DelegateCommand(parameter => { });
sheet1211.ActiveWorksheetEditor.KeyBindings.RegisterCommand(emptyDelegateCommand, Key.Tab);
sheet1211.ActiveWorksheetEditor.KeyBindings.RegisterCommand(emptyDelegateCommand, Key.Tab, ModifierKeys.Shift);
};
webClient.OpenReadAsync(new Uri(filePath));
sheet1211.VisibleSize = new SizeI(13, 45);
I also tried setting it outside, with no avail:
webClient.OpenReadCompleted += (senders, eventArgs) =>
{
var formatProvider = new XlsxFormatProvider();
sheet1211.Workbook = formatProvider.Import(eventArgs.Result);
foreach (Worksheet worksheet in sheet1211.Workbook.Worksheets)
{
worksheets.Add(worksheet);
}
PrepareWorksheet(currWSIndex);
sheet1211.ActiveWorksheet = worksheets[0]; //this line is not needed, just testing if this helps, but it didn't
};
webClient.OpenReadAsync(new Uri(filePath));
sheet1211.VisibleSize = new SizeI(13, 45);
var emptyDelegateCommand = new DelegateCommand(parameter => { });
sheet1211.ActiveWorksheetEditor.KeyBindings.RegisterCommand(emptyDelegateCommand, Key.Tab);
sheet1211.ActiveWorksheetEditor.KeyBindings.RegisterCommand(emptyDelegateCommand, Key.Tab, ModifierKeys.Shift);
0
Accepted
Hi Dexter,
In this case the most suitable moment to set the key bindings would be on the RadSpreadsheet Loaded event.
Please, let me know if you encounter further difficulties.
Regards,
Anna
Telerik
In this case the most suitable moment to set the key bindings would be on the RadSpreadsheet Loaded event.
Please, let me know if you encounter further difficulties.
Regards,
Anna
Telerik
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.