Conditional Display on Continous Form

esskaykay

Registered User.
Local time
Today, 15:41
Joined
Mar 8, 2003
Messages
267
I'm not sure this is possible but.

We have an Access2003 database tracking sewer cleaning. The input form has an INSPECT_DATE, DEBRIS_DEPTH, CLEAN_DATE, and a calculated PERCENT_DEBRIS field (plus a few other incidentals). The form returns only records needed to be field verified. After entering the Inspection_Date and Debris_Depth, if the Percent_Debris field is > 40% the field guys must clean the structure and enter a Cleaned_Date. Here's the kicker - the form's Default View is set to "Continuous Forms" (for various other reasons).

My question -
Is it possible to code so the CLEAN_DATE field only appears if the PERCENT_DEBRIS field is > 40%? In other words, I only want the Clean_Date field to appear on those records where Percent > 40, not all records. I have this working fine if I set the form to "Single Form" but there are other situations that would really confuse the guys in the field if we do this.

Any suggestions would be greatly appreciated.

Thanks,
SKK
 
To do this kind of thing with a view other than Single View requires using Conditional Formatting from the menu, and this has limits. Probably the easiest thing to do would be to simple Disable the CLEAN_DATE field under your conditions.

In Design View, select the CLEAN_DATE field, then goto

Format - Conditional Formatting

and select

Expression Is

then enter

[PERCENT_DEBRIS]<=40

Now click on the Enable/Disable icon (to the right of the big letter A icon)

ClickOK.

If you absolutely have to have the control be invisible unless the condition is met, you'll have to do a lot of diddling with the form. You can use the same conditional expression I gave above to set the Font Color and the Back Color to the same color as the background of the form. The problem then is that the borders of the CLEAN_DATE control will still be visible. You can set this in the Properties pane to Transparent, but that will be the way it looks when it is visible as well, which I don't think looks very professional, unless you make this the default for all textboxes. And when textboxes have their borders set to Transparent, you really have to guess where to click to enter them.

Your choice!

Good luck!
 
Last edited:
Will try...

Thanks again,
SKK
 

Users who are viewing this thread

Back
Top Bottom