jahlxx Posted December 2, 2020 Share Posted December 2, 2020 Hi. When I hide a column in a dbgrid, the column count I think is not correct. If I have 10 columns, column count is 10. but if I hide one column, the column count is 9. This could be ok or not, depending the point of view of every one. Is there any option to get the real number of columns including the hidden columns? Thanks. Quote Link to comment Share on other sites More sharing options...
x11 Posted December 2, 2020 Share Posted December 2, 2020 I checked and my number of columns does not change Quote Link to comment Share on other sites More sharing options...
x11 Posted December 2, 2020 Share Posted December 2, 2020 18 minutes ago, jahlxx said: Is there any option to get the real number of columns first you need to show your code Quote Link to comment Share on other sites More sharing options...
jahlxx Posted December 2, 2020 Author Share Posted December 2, 2020 well, there is no code for this. I hide the column with this, check or uncheck in the columns, to hide and/or show: before uncheck column count is 10, and after uncheck one, the column is hidden and the column count is 9. Quote Link to comment Share on other sites More sharing options...
x11 Posted December 2, 2020 Share Posted December 2, 2020 Just now, jahlxx said: before uncheck column count is 10, and after uncheck one, the column is hidden and the column count is 9. checkboxes for and DESIGNED to hide and show columns Quote Link to comment Share on other sites More sharing options...
jahlxx Posted December 2, 2020 Author Share Posted December 2, 2020 ups. sorry!! can you clarify? thanhs. Quote Link to comment Share on other sites More sharing options...
x11 Posted December 4, 2020 Share Posted December 4, 2020 checkboxes DESIGNED to hide and show columns Quote Link to comment Share on other sites More sharing options...
Abaksoft Posted December 4, 2020 Share Posted December 4, 2020 @jahlxx Confirmed : No problem with Columns.Count. Unigui Build 1539. See example in attachment Project1.7z Quote Link to comment Share on other sites More sharing options...
x11 Posted December 4, 2020 Share Posted December 4, 2020 Maybe jahlxx doesn't know or doesn't understand what checkboxes are for? Quote Link to comment Share on other sites More sharing options...
jahlxx Posted December 4, 2020 Author Share Posted December 4, 2020 Well, perhaps. I think I understand, but could be wrong. As I know, the checkboxes are to hide show columns in the grid. And as I can see, if I hide a column, the columncount returns a different vale. And fom my point of view, the columncount should not change. The count of columns should be the same, because I have 9 visible columns and 1 hidden column, 10 columns in total, not 9. Quote Link to comment Share on other sites More sharing options...
Abaksoft Posted December 4, 2020 Share Posted December 4, 2020 22 minutes ago, jahlxx said: 10 columns in total, not 9. Hello jahlxx, Wich Unigui Build are you using ? Did you try my previous example ? Quote Link to comment Share on other sites More sharing options...
jahlxx Posted December 4, 2020 Author Share Posted December 4, 2020 Version 1.90.0.1539 I saw your example, and I think that the problem is that you have defined columns ai design time, and I define columns in run-time. That's the problem. In thar case, the counter fails. Quote Link to comment Share on other sites More sharing options...
Abaksoft Posted December 4, 2020 Share Posted December 4, 2020 Mmm....OK You should ask our Maestro Sherzod Quote Link to comment Share on other sites More sharing options...
Sherzod Posted December 4, 2020 Share Posted December 4, 2020 3 hours ago, jahlxx said: I saw your example, and I think that the problem is that you have defined columns ai design time, and I define columns in run-time. That's the problem. In thar case, the counter fails. Hello, Sorry, can you please make simple testcase to see the issue? Quote Link to comment Share on other sites More sharing options...
x11 Posted December 5, 2020 Share Posted December 5, 2020 On 12/2/2020 at 1:33 PM, x11 said: first you need to show your code I already asked 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.