Grid using Inline Editing and using tab key like in batch edit mode and creating new records when last row is validated to valid

Good Evening,

Using the grid in inline edit mode to enter records as entering rows in an invoice manner.

Filling the first row and tabing at the last column, if the row is valid continue by creating a new row with the first editable column in edit mode and continue to do for as many rows you want.

The grid now,  when editing in inline mode end tabing in the last column, the focus  moves away from the grid to the first element in the page. 
How can we control the tab key from not moving the focus away from the grid but to move to the next row in the grid, also the same for shift+tab moving backwards like in the batch editing mode

Thank you in advance
Best regards
Panikos Frangoudes





3 Replies 1 reply marked as answer

RS Renjith Singh Rajendran Syncfusion Team February 26, 2021 02:44 AM UTC

Hi Frangoudes , 
 
Greetings from Syncfusion support. 
 
We have checked your query and we would like to inform you that we do not have direct support for the requested behavior. we suggest you to invoke the AddRecord method of grid on pressing the tab key in the last column. We have prepared a sample for your reference. 
 

Please get back to us if you have any other queries. 

Regards, 
Renjith R 


Marked as answer

BA BAx April 23, 2021 08:11 PM UTC

As additional note, when adding the record after the TAB the focus gets lost.
This was an issue for me, so  I found a way to select the new row and focus it.

// creates the new record with a unique identifier
var newRecord = new Item() {Id = myId }
// adds the record
await GridInstance.AddRecord(newRecord);
// retrieves the index by primary key
var ix = await GridInstance.GetRowIndexByPrimaryKey(myId);
// selects the record / row
await GridInstance.SelectRow(ix);
// edits it
await GridInstance.StartEdit();

I hope it helps!




JP Jeevakanth Palaniappan Syncfusion Team April 26, 2021 04:53 AM UTC

Hi BAx, 

We are glad that you have achieved your requirement by using the public methods. Please get back to us if you have any other queries. 

Regards, 
Jeevakanth SP. 


Loader.
Up arrow icon