This is a migrated thread and some comments may be shown as answers.

RadGridView text box and OSK

2 Answers 207 Views
GridView
This is a migrated thread and some comments may be shown as answers.
J
Top achievements
Rank 1
J asked on 20 Nov 2017, 11:23 AM

When I click the grid view's "add new item" button, it shows a text box where to type in the value for the new row. I want show Window's on screen keyboard when the text box is clicked/tapped. I.e., I start a new Process that starts TabTip.exe for every other text box in my application.

Is there an easy way to do this with the grid view's text box or do I have to override a certain grid view's style? If so, which one?

I took a quick look at the your style structure topic but couldn't find the text box in the styles. I think the text box container is PART_DataCellPresenter because the text box was not displayed after I commented PART_DataCellPresenter out in the style.

The way I have handled this with other text boxes is that I have created a new class that extends TextBox. Then I subscribed to the PreviewLeftMouseUp event whose handler starts TabTip.exe. Maybe I can override some grid view's style to use my extended class or if you have a better solution.

2 Answers, 1 is accepted

Sort by
0
Dilyan Traykov
Telerik team
answered on 23 Nov 2017, 08:57 AM
Hello J,

The suggested approach in this scenario would be to create a custom column editor as demonstrated in this article. In the CreateCellEditElement override of your custom column you can return the extended TextBox class to handle the editing as per your requirements.

Please let me know if you find this applicable.

Regards,
Dilyan Traykov
Progress Telerik
Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
0
J
Top achievements
Rank 1
answered on 11 Dec 2017, 01:48 PM

Just what I wanted, thanks.

I actually created an extended class from GridViewDataColumn class. Then overrode the CreateCellEditElement method. Then subscribed to the PreviewMouseLeftButtonUp event of the TextBox object that the base.CreateCellEditElement method call returns. The event handler then starts the TabTip.exe process.

Tags
GridView
Asked by
J
Top achievements
Rank 1
Answers by
Dilyan Traykov
Telerik team
J
Top achievements
Rank 1
Share this question
or