Command button on form problem

Orson9750

Registered User.
Local time
Today, 07:36
Joined
Mar 9, 2009
Messages
41
I've created a form with 3 subforms. They are functioning well. However, the form looks quite busy. To clean up the form, I created command buttons to open the 3 forms used as subforms.

Problem: When I click on the command button and choose a value from the form. That same value is shown for every record in the main form.

Example: Main form: Company ABC, Company XYZ. Subform: Orders
I would enter a order for pencils; erasers. all good however pencils and erasers also shows up for Company XYZ. What am I missing in my command button?

I welcome your expertise.
 
Are you saying that instead of the other form being displayed as a SubForm on your MainForm you are now opening them as separate forms? If so, the LinkChild/MasterFields no longer apply. You can probably just use the WhereCondition argument of the OpenForm command to apply a filter to the next form's RecordSet.
 
Last edited:
Allan's suggestion is valid, if you really want to go the open this form then open that form... routr, but the usual "busy form tamer" for this kind of situation is the Tabbed Control. Place a tabbed control on your form and place each of your subforms on a page. This will allow the LinkChild/MasterFields function to work again, as before, and save you a lot of work and aggravation, I suspect.
 
I am attempting to use a Open Form command button to open my subform instead of having the subform displayed on my main form. The command button looks better. The command button opens my subform ok but now the subform does not work. Using the open form command button for this subform -- well now I have problems with information I add to one record duplicates itself on the next record.

The subform by itself on the form worked well without problems and I can not figure out why the same subform does not work using the command button.

Many thanks for any advise.
 
Are you using the WhereCondition argument to put a filter on the other form?
 
Thanks Rural Guy. Great tip. The tabbed control did the trick.
 

Users who are viewing this thread

Back
Top Bottom