Sorry Rudy, not an answer to your question, but topical I think.

Being able to create a sophisticated form via code is a fantastic feature. It 
is like the coding I did back in 1982/1983. Back when I first got my hands on 
my own copy of 4D version 2.0.10  the Graphical form editor was such a 
liberating way of creating forms, compared to the way I needed to do it in 
Pascal.

This really is a great feature, but my hope is that this is just a necessary 
1st step to being able to create a form using the normal 4D Form Editor, Form 
Method, Object Methods and then be able to save them as ‘text’ that can then be 
sent to clients.

We have often had the need to send multiple forms to different clients for them 
to run.  Then the client needs / forced to (by regulations) have a new version 
of the form. That is great, but they still have lots of data that they collect 
via the old form and need to be able to display that data in the form they used 
at the time. 

In the last major application we did, we have ~ 10,000 forms with each client 
having about 150 of them. Each client though would have a different set of 
forms. When 4D announced this feature I hoped that it will lead to fulfilling 
this need. Then as 4D developers we can provide a rich, consistent interface 
within the product rather than having to resort to forms in WebAreas, PDFs, 
etc. This will help us 4D developers stick within our expertise of 4D and be 
more productive.

Jody Bevan
Argus Development Inc.


> On Sep 24, 2018, at 8:44 AM, Two Way Communications via 4D_Tech 
> <[email protected]> wrote:
> 
> I can’t figure out how to do this … 
> 
> Using a dynamic form, I am trying to build a generic list of records to 
> display to the user and to allow him to select 1 record.
> 
> I used the example from the tech note on how to create a dynamic form that 
> shows a listbox.
> 
> To build this $form object variable, the commands New object and others are 
> used.
> 
> This listbox object is added to the $page object in the $form object, which 
> will be used in the DIALOG command.
> 
> 
> $obj:=New object("type";"listbox";"listboxType";"collection";\ 
> "dataSource";$colName;"left";0;"top";0;"width";$width+15;"height";$height)
> 
> 
> 
> $page:=New object("objects";New object("myListBox";$obj)) $form:=New 
> object(“pages";New collection(Null;$page))
> 
> $form:=New object("windowTitle";"Select a 
> Map:";"windowMinWidth";500;"windowMinHeight";300;"pages";New 
> collection(Null;$page))        
> 
> Now, this dynamic form only shows a listbox, and I want to add a button to 
> the form. I assume this button object has to be added to the ‘Objects’ object 
> in $page.
> 
> But, how do I do that? I tried object arrays and collections, but neither of 
> them produces the correct result. 
> 
> 
> Secondly, the listbox displays an entity selection. How do I get the row 
> number that has been selected?
> 
> 
> 
> Regards,
> 
> Rudy Mortier
> Two Way Communications bvba 
> 

**********************************************************************
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