Thanks. Now I'm able to enable editable field by double click.
We are planning to enable editable field also on any valid character key press and want to retain the pressed character in the editable field. But this is not achievable since it takes some time to render editable field. Please guide us if we can do this in any other way.
Thanks in advance,
Sam Azpan. D
answered on 20 Aug 2018, 07:38 AM
This may be possible to achieve based on the field editors that you have. If all columns in your Grid are strings and you have simple text editors, you can try the following:
1. When you capture the key press event and check what letter was pressed, save this letter in a variable that is accessible to the Grid event handler functions.
2. Add an edit event handler to the Grid. When you call editCell to make the cell editable, this event will be raised jut before showing the cell content.
3. In the edit event handler, you can search for the edited input and set its value to the letter that you previous saved:
var input = e.container.find("input.k-textbox");
input.trigger("change"); // if you want the value to be immediately reflected in the underlying data item
If you have other editors like DatePickers or NumericTextBoxes, you will need to run additional checks to know what type of editor you need to be setting the current value to.
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers.Learn More.