Setting datagrid table column to non-user-editable.
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Setting datagrid table column to non-user-editable.
Hi,
Can anyone tell me aa EASY way to select a column in a dg table and set it to non-user-editable ?
Can anyone tell me aa EASY way to select a column in a dg table and set it to non-user-editable ?
Re: Setting datagrid table column to non-user-editable.
Hi CAsba,
you need to use the message box for that:
Best
Klaus
you need to use the message box for that:
Code: Select all
set the dgColumnIsEditable["your column name here"] of group "your datagrid group here" to FALSE
Klaus
Re: Setting datagrid table column to non-user-editable.
Or, if you could just create a behaviour for the column in question and comment out the contents of the mouseDoubleUp handler for that column…
Re: Setting datagrid table column to non-user-editable.
Sure, but that would be taking a sledgehammer to crack a nut!
Re: Setting datagrid table column to non-user-editable.
Perhaps but as I always create behaviours for columns (either to do an action, add controls such as checkboxes or even just set margins to correct vertical alignment as I find the default row height very stingy), it is but a minor issue to just adjust the mouseDoupleUp handler. Plus don’t have to remember yet another command
Re: Setting datagrid table column to non-user-editable.
Thank you, gentlemen, that's been a great help.
Re: Setting datagrid table column to non-user-editable.
Hi Klaus,
That was a real simple and effective line of code. Is there a source of such snippets like that for all the other property variants to manage datagrids ?
That was a real simple and effective line of code. Is there a source of such snippets like that for all the other property variants to manage datagrids ?
Re: Setting datagrid table column to non-user-editable.
Hi CAsba,
I worked through all of these LC lessons:
https://lessons.livecode.com/m/datagrid
https://lessons.livecode.com/m/datagrid_tips
A DataGrid is currently the most complex beast in LC, but worth the effort to master it!
There has been a PDF with all of these lesson of the LC webpage, but that is not available anymore.
I put my copy into my Dropbox, get it here if you like:
https://www.dropbox.com/s/l1cqiohy2it3e ... d.pdf?dl=1
Best
Klaus
I worked through all of these LC lessons:
https://lessons.livecode.com/m/datagrid
https://lessons.livecode.com/m/datagrid_tips
A DataGrid is currently the most complex beast in LC, but worth the effort to master it!
There has been a PDF with all of these lesson of the LC webpage, but that is not available anymore.
I put my copy into my Dropbox, get it here if you like:
https://www.dropbox.com/s/l1cqiohy2it3e ... d.pdf?dl=1
Best
Klaus
Re: Setting datagrid table column to non-user-editable.
Thanks, Klaus, I picked up the list, many thanks.