On Jan 30, 2019, at 1:33 PM, Keisuke Miyako via 4D_Tech <[email protected]> 
wrote:
> 
> by the way, I just tested, setting the element to #0 of populated default 
> value/text array popup menu works fine.
> 
> are you using process variables or form local (anonymous) variables?
> are you running interpreted or compiled?
> what is the value type of the popup menu object?

This is an old-style process variable declared as text array. The 
popup/dropdown displays the 0 element value properly when the array is empty, 
but does not display it when the array has elements.

> the example DB I posted earlier in this thread uses New list and OBJECT SET 
> LIST BY REFERENCE.
> the list can be totally dynamic, it does not need to exist in the toolbox.

I had looked at the code and didn’t see that, but noticed the objects on the 
form appeared to have a choice list set in the property editor.

This sounds like it could clean up the tedium of using text arrays with 
popup/dropdowns with just a couple convenience methods to set up and tear down 
an object. The documentation for New List suggests that the list should be 
cleared when no longer needed by calling CLEAR LIST, so I guess each element 
will need to do that when unloading the form. Too bad there’s no reference 
counting so the dynamically created lists could automatically be cleared when 
no object or variable currently holds a reference.

Jim Crate

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to