470,831 Members | 1,445 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,831 developers. It's quick & easy.

Field list in combo of a table from another combo

97 64KB
On a form, I have a combo box with list of tables using 'msysobjects.name'. I want another combo showing list of fields of the table name selected in first combo. How is this possible? Please help me. Thank you.
Apr 10 '21 #1
4 5320
32,311 Expert Mod 16PB
This is a very poor question. There are no signs you've done any work whatsoever before posting this. The best I can do at this point is to point you towards Cascaded Form Filtering which certainly can help you.

If you get stuck then post back explaining clearly what you've tried and what you don't understand.
Apr 11 '21 #2
97 64KB
Thank you. I have got idea.
Apr 11 '21 #3
3,653 Expert Mod 2GB
In general, you would need to use VBA to use the Table object and cycle through all the fields, assigning that list to the second combo box. The challenge is getting the list of fields into a recordset that is usable by the combo box. The only way I know how to do that is by using an ADODB recordset.

But, other than this advice, I am not going to build this for you when you have not put forth any effort to work through this yourself or show any of your work thus far.
Apr 12 '21 #4
358 Expert Mod 256MB
You may find some useful DAO code on Allen Browne's website. For example, Show Fields in a table & Show Field Names & Types from a table or query
Apr 12 '21 #5

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

8 posts views Thread by Ward B | last post: by
1 post views Thread by Old Timer | last post: by
1 post views Thread by prakashwadhwani | last post: by
6 posts views Thread by henry.onovwaka | last post: by
reply views Thread by mihailmihai484 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.