469,600 Members | 2,444 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

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

Want my subform info to autopopulate...

I have a main form with customer names & addresses, and a subform that
I want to have the following: I wish to pull up an equipment name with
a combo box (from my "equipment" table); then have the unit price and
a monthly maximum charge auto-populate in the subform (both values are
in the "equipment" table as well). Why am I having such a tough time
with this? Have tried to create a form/subform with both the wizard
and the toolbox/subform tool. Not having any luck. Suggestions?
Thanks in advance.
Nov 12 '05 #1
2 3036
You might want to create a query on the fly and use the following:

Air Code

Field1 = querycombo.column(0)
Field2 = querycombo.column(1)
Field3 = querycombo.column(2)

etc etc

Rename the fields names to the textboxes you wish to auto populate. Rename the
combox to the name of your combobox and use the code in the afterupdate.

HTH

Michael
Nov 12 '05 #2
Fork_In_Road wrote:
I have a main form with customer names & addresses, and a subform that
I want to have the following: I wish to pull up an equipment name with
a combo box (from my "equipment" table); then have the unit price and
a monthly maximum charge auto-populate in the subform (both values are
in the "equipment" table as well). Why am I having such a tough time
with this? Have tried to create a form/subform with both the wizard
and the toolbox/subform tool. Not having any luck. Suggestions?
Thanks in advance.


Besides advice already provided...MF = Main form, SubForm = SF. You
reference a field like this
Forms!MF!SF!ID = ...
Or
Me!SF!ID = ...

To get the recordsource of SF you enter
strSource = Forms!MF!SF.Form.RecordSource

Nov 12 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by jbroome | last post: by
2 posts views Thread by Fork_In_Road | last post: by
1 post views Thread by Stephen D Cook | last post: by
reply views Thread by suresh191 | last post: by
4 posts views Thread by guiromero | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.