MOGSY Posted May 17, 2021 Share Posted May 17, 2021 Hi How is possible to dynamically disable or enable selection. Following code disables selection how is possible to do this dynamically from the code. function beforeInit(sender, config) { sender.disableSelection = true; } regards Quote Link to comment Share on other sites More sharing options...
Sherzod Posted May 17, 2021 Share Posted May 17, 2021 1 hour ago, MOGSY said: How is possible to dynamically disable or enable selection. Following code disables selection how is possible to do this dynamically from the code. Hello, Sorry, why do you need this? Quote Link to comment Share on other sites More sharing options...
MOGSY Posted May 17, 2021 Author Share Posted May 17, 2021 Hi Sherzod I have a result grid that shows the result of a search, it is confusing when a row is highlighted while the grid has no focus, I need to highlight the selected row when the grid has focus, otherwise it gives the impression that the grid has focus. Regards Quote Link to comment Share on other sites More sharing options...
Sherzod Posted May 17, 2021 Share Posted May 17, 2021 36 minutes ago, MOGSY said: I have a result grid that shows the result of a search, it is confusing when a row is highlighted while the grid has no focus, I need to highlight the selected row when the grid has focus, otherwise it gives the impression that the grid has focus. Not very clear to me. But try: UniDBGrid1.JSInterface.JSCall('getSelectionModel().setLocked', [True]); Quote Link to comment Share on other sites More sharing options...
MOGSY Posted May 17, 2021 Author Share Posted May 17, 2021 Hi Sherzod Thank you for your reply, unfortunately the effect of this is that up arrow stops working and one can't press up arrow to move back up the records. I have tried using dgRowSelect of the Unidbgrid options property, however the same issue occurs with disabling and enabling of this property, up arrow stops working and it appears that it changes the focus from the unidbgrid. regards Quote Link to comment Share on other sites More sharing options...
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.