sync'd combo boxes on subform

G

Guest

Ok, let me see if I can describe this well enough to be understood.

I have a form which holds customer main information, then I have a subform
which has tab controls. I have combo boxes and text boxes that are enabled
or disabled depending on what the user chooses. The problem is that what is
enabled or not needs to stay within the individual record of the subform.
However, what is happening is that if a user chooses one thing on the first
record and then moves to a new record (on the subform) and chooses something
different it enables fields that shouldn't be enabled on the first record.
Is there anyway to prevent this from happening?
 
M

Marshall Barton

Charlie said:
I have a form which holds customer main information, then I have a subform
which has tab controls. I have combo boxes and text boxes that are enabled
or disabled depending on what the user chooses. The problem is that what is
enabled or not needs to stay within the individual record of the subform.
However, what is happening is that if a user chooses one thing on the first
record and then moves to a new record (on the subform) and chooses something
different it enables fields that shouldn't be enabled on the first record.


You need to use the enable/disable code for all the options
in the subform(?) Current event in addition to each
individual control's AfterUpdate event.
 
G

Guest

That is exactly what I have. The problem comes in when moving through the
records on the subform; the next record will change the first records txt
boxes, etc. that are enabled or disabled. Is there a way to prevent that?
 
M

Marshall Barton

Are you saying the subform is in continuous view?

If that's the case, then you can not use a VBA procedure to
enable/disable controls without getting the visual effect
you are trying to avoid.

Instead, you need to use Conditional Formatting (Format
menu) on each of the controls that you want to
enable/disable.
 
G

Guest

No it is not a continous form. The view is "form" view", each tab is a
different section pertaining to the case associated with the member info on
the main form. A member can have mulitple cases that is why the subform
(tab's) has multiple records associated with it. However the view is not
datasheet or a continues form.

Marshall Barton said:
Are you saying the subform is in continuous view?

If that's the case, then you can not use a VBA procedure to
enable/disable controls without getting the visual effect
you are trying to avoid.

Instead, you need to use Conditional Formatting (Format
menu) on each of the controls that you want to
enable/disable.
--
Marsh
MVP [MS Access]

That is exactly what I have. The problem comes in when moving through the
records on the subform; the next record will change the first records txt
boxes, etc. that are enabled or disabled. Is there a way to prevent that?
 
M

missinglinq via AccessMonster.com

I'm confuse! If the subform's records aren't being shown datasheet or
continuous how do you know what record B is doing to the controls on record A?

No it is not a continous form. The view is "form" view", each tab is a
different section pertaining to the case associated with the member info on
the main form. A member can have mulitple cases that is why the subform
(tab's) has multiple records associated with it. However the view is not
datasheet or a continues form.
Are you saying the subform is in continuous view?
[quoted text clipped - 20 lines]

--
There's ALWAYS more than one way to skin a cat!

Answers/posts based on Access 2000

Message posted via AccessMonster.com
 
M

Marshall Barton

Then it sounds like you might have a problem coordinating
the multiple subforms. You might(?) be able to overcome at
least part of this problem if you don't enable/disable all
the subforms from the main form and use each subform's
Current event instead ( and possibly the tab control's
Change event.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top