arilotta Posted July 9, 2018 Share Posted July 9, 2018 Hi all, I have a DbGrid with dgEditing=true. I would like to limit the columns that can be selected, because some contains icons and some other are text read-only. I am struggling with ClientEvents and CellModel, but I not so familiar with JS and I am wasting too much time. So, how can I limit my grid to only focus on the third column for example ? Thanks you all Andrea Quote Link to comment Share on other sites More sharing options...
Sherzod Posted July 9, 2018 Share Posted July 9, 2018 Hi, At the moment, the column index is passed through "eOpts", and you can try this approach I think: function cellModel.beforeselect(sender, record, index, eOpts) { //colIndx = 2 return (eOpts == 2); } Quote Link to comment Share on other sites More sharing options...
arilotta Posted July 10, 2018 Author Share Posted July 10, 2018 Hi Delphi Dev, unfortunately I don't have the "beforeselect" event on cellModel, just these 4: - deselect - focuschange - select - selectionchange How come ? Quote Link to comment Share on other sites More sharing options...
Sherzod Posted July 10, 2018 Share Posted July 10, 2018 Hi, Wich build are you using ?! Quote Link to comment Share on other sites More sharing options...
arilotta Posted July 10, 2018 Author Share Posted July 10, 2018 build 1425 Quote Link to comment Share on other sites More sharing options...
arilotta Posted July 11, 2018 Author Share Posted July 11, 2018 Hi Delphi Dev, is "beforeselect" event not supported in build 1425 ? Quote Link to comment Share on other sites More sharing options...
Sherzod Posted July 11, 2018 Share Posted July 11, 2018 Hi, Hi Delphi Dev, is "beforeselect" event not supported in build 1425 ? Unfortunately, does not support 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.