In binary databases, there is an option for lists to be editable by users other than the designer. Users that have access to these lists may only add, modify, or delete items within the list; they cannot delete the list itself, nor can they create or delete any other list in the database.
Image 1. Special dialog window allowing users to modify a list*
In 4D versions 17 and below, there was a checkbox in the list editor section of the Toolbox window; in v18 and up, however, this feature has since been deprecated and was not made available in project mode.
Image 2. The “editable by user” checkbox found in the Toolbox window (in v17 and below only)*
As a workaround, you can use the block of code below to first load the list, get all of its current properties, and just set the “editable” parameter to allow users to modify the list.
Code Block: Set the “editable by user” property of a list
// declare variables var $sampleListRef : Integer // get listRef $sampleListRef:=Load list("SampleList") // get list properties GET LIST PROPERTIES($sampleListRef; $appearance; $icon; $lineHeight; $doubleClick; $multiSelections; $editable) // set list properties SET LIST PROPERTIES($sampleListRef; $appearance; $icon; $lineHeight; $doubleClick; $multiSelections; 1) // set “editable” parameter to 1 |
*Note: Images 1 and 2 are taken from this page in the 4D documentation website.