I am using the XamNumericEditor with a mask of {}{double:0.2} - no whole numbers, only 2 decimal places. When the control is initially loaded, the keyboard focus is on the left of the decimal and I have to move it over to the right of the decimal in order to gain keyboard up/down control over the value. Is there a way to set keyboard focus to the far right of the box initially?
Hello nwnerd,
In order to do this, I would recommend that you utilize the SelectionStart property of the XamNumericEditor, and set it in the EditModeStarted event of that control. Currently, with a Mask of {}{double:0.2}, there would be a maximum indexed position of 3, and so if you use the following code, you can set the cursor to the right-side of the editor upon entering edit mode:
private void numericEditor_EditModeStarted(object sender, Infragistics.Windows.Editors.Events.EditModeStartedEventArgs e){ numericEditor.SelectionStart = 3;}
Please let me know if you have any other questions or concerns on this matter.
Sincerely,AndrewAssociate Developer