jahlxx Posted December 13, 2016 Posted December 13, 2016 hi. - how to direct input data in a unistringgrid? the user can't direct type data in the grid. must type <RETURN> before - can I define maks for every column? - how can I control the change of the value of a cell? thanks. Quote
Sherzod Posted December 14, 2016 Posted December 14, 2016 Hi, - how to direct input data in a unistringgrid? the user can't direct type data in the grid. must type <RETURN> before For now can you try this quick solution?!But there may be a problem, if a user directs the input data very quickly... UniStringGrid1 -> ClientEvents -> ExtEvents -> function keydown: function keydown(sender, key, shift, eOpts) { var btn=sender.button; if (btn == 36 || btn == 37 || btn == 38 || btn == 39) { return false; }; var me=this.normalGrid; if (me && me.editingPlugin) { if (!me.editingPlugin.editing) { me.editingPlugin.startEditByPosition(me.getSelectionModel().getCurrentPosition()); me.editingPlugin.getActiveEditor().field.selectText(); } } } Best regards. Quote
zanona Posted November 7, 2018 Posted November 7, 2018 Did not work! I'm using version 1.50.0.1481 Quote
Sherzod Posted November 7, 2018 Posted November 7, 2018 Just now, zanona said: Did not work! I'm using version 1.50.0.1481 I know, need to correct this code... 1 Quote
Sherzod Posted November 7, 2018 Posted November 7, 2018 Can you try this code ?: function keydown(e, t, eOpts) { var me = this.ownerGrid, currPos = me.getSelectionModel().getCurrentPosition(); if (!currPos.view.isLockedView) { var btn = e.keyCode; if (btn == 37 || btn == 38 || btn == 39 || btn == 40) { return false; }; if (me && me.editingPlugin) { if (!me.editingPlugin.editing) { //me.editingPlugin.startEditByPosition(me.getSelectionModel().getCurrentPosition()); me.editingPlugin.startEditByPosition({ row: currPos.row, column: currPos.column + me.fxCols }); me.editingPlugin.getActiveEditor().field.selectText(); } } } } Quote
zanona Posted November 7, 2018 Posted November 7, 2018 It worked partially! When digit occurs editing the cell to the right never the one that was selected Quote
Sherzod Posted November 7, 2018 Posted November 7, 2018 20 minutes ago, zanona said: It worked partially! When digit occurs editing the cell to the right never the one that was selected Please explain Quote
zanona Posted November 7, 2018 Posted November 7, 2018 When I type in the selected cell the focus goes to the cell to the right allowing you to enter the value! I had to edit the selected cell and not play the focus for the cell phone right! Quote
Sherzod Posted November 7, 2018 Posted November 7, 2018 I'm sorry, I don't understand your issue Can you make a screenshot by indicating where the problem is ? Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.