Ask Your Question
0

How do you in base create a form where a linked field gets its list of values?

asked 2017-04-27 19:21:26 +0200

jocko1 gravatar image

How do you in base create a form where a linked field gets its list of values?

example :

I have 2 tables table 1 is pre loaded the other table 2 enters data linked by relationship (table 1) 1 to many (table 2) the form is created using table 2 fields and one of the fields becomes a list of values from table 1 and the record is only saved to table 2

edit retag flag offensive close merge delete

Comments

The example given in this Q gives you a live one to play with.

EasyTrieve gravatar imageEasyTrieve ( 2017-04-27 22:19:48 +0200 )edit

1 Answer

Sort by » oldest newest most voted
0

answered 2017-04-27 21:22:41 +0200

librebel gravatar image

updated 2017-04-27 21:23:28 +0200

Hello jocko1,

1) Add a Listbox control to your Form
2) Right-click on the Listbox control and select the option "Control..."
3) In the Properties dialog that pops up, in the tab "General", set the option "Dropdown" to Yes
4) in the tab "Data":
    set the "Data field" to the name of your bound field from table 2,
    set the "Type of list contents" to Sql,
    set the "List content" to an SQL select statement like: "SELECT 'FIELD1', 'ID' FROM 'TABLE1'"
    set the "Bound field" to 1      ( referring to the field 'ID' in the SQL statement above )
edit flag offensive delete link more

Comments

Thank you! Your answer and explanation is great!

jocko1 gravatar imagejocko1 ( 2017-04-27 23:33:10 +0200 )edit

you're welcome:)

librebel gravatar imagelibrebel ( 2017-04-28 00:59:41 +0200 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2017-04-27 19:21:26 +0200

Seen: 908 times

Last updated: Apr 27 '17