we are using subforms a lot and often nested.
Some commands can only be called, if a form is completely initialized or like in the case of 4D Write Pro, if the command is called in the context of the form in which the 4D Write Pro Area is located.
Currently we need to know the path of object names (subforms) in order to get the call form in the right context.
Having this path we currently call
“Call form(current form window;“myMethod”;$collectionOfObjectNames;$Param1;…)”
and inside the method
execute method in subform($1.shift();current method name;*;$Param1;…)
//Do the job
This approach works, but
- you need to know the nesting and this requires that you have to pass the names through every nesting step of subforms
- it’s slow and cumbersome
The feature request:
- New command: “Current form ref” (or extend “Current form window” with (*)) for getting an id to be used for calls of “call form”
- Extend the command “Call form” to accept the “formId” and forward the call directly to the subform context.
This would simplify componentized development using forms in 4D extremely.