on 02-18-2008 12:10 PM
Hello,
I use a table to populate an input form.
the input form defines the table's fields as default,
when clicking a row in the table the form is populated / updated.
the input form has a submit-button which triggers the CLEAR event on this form.
however the row selected in the table to populate the form is also cleared, it seems there is some reference instead of a rowdata-copy.
any idea how to copy the selected data from the table into the form instead of creating sth like a reference, which is affected by a CLEAR-event?
thanks,
kai
Hi Kai,
The behavior you describe is the default behavior in VC.
As you already noticed the table in your model is connected to the form in in Bind Link.
Bind links differ from other links in their green color and right angels. As seen in the attached image "bing_link.png".
There is no straight forward way to connect a table to a form with a map link (curved blue line, with a notch near its start).
Here is one way:
- Drag a Switch Operator onto the board and place it between the table and the form.
- Right click the Switch Operator and select "Remove Port" so you will have only a single port on the Switch.
- Connect the Table output port to the Switch input port
- Right click the switch and select "Define Operator".
- Use the plus button on the Define Switch popup to add fields tp the operator. Add a field for every field you wish to map from the table to the form.
- Map each input field to an output field with the same name (the default behavior). See attached screenshot "define_switch.png" to see how it should look.
- Connect the from to the Switch.
- Right Click the form and select "Define Data". Set all the data fields to be visible on the form.
- Add a clear button to the form.
- See attached model screen shot "mapping_using_switch.png"
I hope this helps,
Shai
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Kai,
I uploaded the images to a public image hosting site:
here are the links:
http://img518.imageshack.us/img518/6342/bindlinkbr9.png
http://img183.imageshack.us/img183/6865/defineswitchot4.png
http://img142.imageshack.us/img142/8446/mappingusingswitchcv7.png
Regards,
Shai
User | Count |
---|---|
101 | |
13 | |
13 | |
11 | |
11 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.