VBA Beginner Needs Direction - Conditional Formatting

  • Thread starter Mark S via AccessMonster.com
  • Start date
M

Mark S via AccessMonster.com

I am trying to do conditional formatting on a main form/subform. The subform
depends on the main form. If main form is x and main form is y then subform
field is red if under x. Can this be accomplished using Expression/Field or
should I venture into using VBA? I am totally new @ VBA.

Any help is greatly appreciated.
 
W

Wayne Morgan

Yes, this can be accomplished using Expression Is (you may even be able to
use Field Value Is - Less Than) in the Conditional Formatting settings for
the control. The trick is the syntax to refer to a control on the subform
from the main form or to refer to a control on the main form from the
subform.

If the control you are wanting to use the conditional formatting on is on
the subform, then to refer to the control on the main form the syntax you
would use in the Conditional Formatting dialog would be:

[Parent]![ControlName]
 
M

Mark S via AccessMonster.com

Thanks Wayne....I'll give it a try.

Wayne said:
Yes, this can be accomplished using Expression Is (you may even be able to
use Field Value Is - Less Than) in the Conditional Formatting settings for
the control. The trick is the syntax to refer to a control on the subform
from the main form or to refer to a control on the main form from the
subform.

If the control you are wanting to use the conditional formatting on is on
the subform, then to refer to the control on the main form the syntax you
would use in the Conditional Formatting dialog would be:

[Parent]![ControlName]
I am trying to do conditional formatting on a main form/subform. The
subform
[quoted text clipped - 5 lines]
Any help is greatly appreciated.
 

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