Conditional Formatting stopped working

G

Guest

In my report, I have a text field where I have set the Conditional Format to
turn the text red if values in 2 other fields are between 28 and 40. It was
working fine, then for some reason it stopped working. I had a backup of the
database so I could compare code, properties, etc, and everything is still
the same. Any ideas as to what would have caused it to stop working?

Thanks in advance for any guidance and help.
 
G

Guest

Are the values you are comparing actually numeric or does Access think they
are text?
 
G

Guest

They are numeric, and I tried changing the properties to General Number, and
that didn't help. Here's the stranger thing we found out later tonight.
This dbase has multiple users. 7 to be exact, and the formatting isn't
working for any of us, but one person does have it show and print correctly.
Any ideas?

Thanks again.

Shawn-rika
 
G

Guest

I'm not familiar with an issue like this. I would check printer drivers,
references, and service packs.
 
G

Guest

I've done some more research on this problem and haven't come up with
anything. Here's more info...
the different computers are running XP or 2000, with Service Packs 2 or 4.
I am thinking that a windows update may have caused the problem. Where would
I get help with figuring out this problem if this discussion group can't help?

Thanks a bunch for all your help.
 
G

Guest

I am not sure how to get the conditional formatting to work. I can't "play"
with your expressions (or even see them) from my PC :)

You can use code in the On Format event of your report section to modify
formatting.
 
G

Guest

Here's the expression I used in the "Expression Is" criteria that was working
fine before and currently working on one users computer.

(([IN 1] Between 28 And 40) And ([SC 1] Between 28 And 40)) Or (([IN 1]
Between 28 And 40) And ([AT 1] Between 28 And 40)) Or (([SC 1] Between 28 And
40) And ([AT 1] Between 28 And 40)) Or ([BC 1] Between 60 And 72)

Any thoughts?

Thanks,
 
G

Guest

You can take the complex expression out of the Conditional Formatting and put
it in your query and possibly use a small user-defined function. For
instance, I created a report in the Northwind mdb using the Orders table. I
first wrote a small function in my "modBusinessCalcs" module:

Public Function FormatShipDate(curFreight As Currency, intVia As Integer) As
String
If curFreight > 100 And intVia = 3 Then
FormatShipDate = "Red"
Else
FormatShipDate = "Green"
End If
End Function

I call the function in the conditional formating like:
Expression Is: FormatShipDate([Freight],[ShipVia])="Green"

This takes your business logic/calcs out of conditional format expressions
(where it shouldn't be) and puts it in your module for business calcs (where
it should be). Then when your business logic changes, you go to your module
to maintain rather than your report design.
--
Duane Hookom
Microsoft Access MVP


SVE said:
Here's the expression I used in the "Expression Is" criteria that was working
fine before and currently working on one users computer.

(([IN 1] Between 28 And 40) And ([SC 1] Between 28 And 40)) Or (([IN 1]
Between 28 And 40) And ([AT 1] Between 28 And 40)) Or (([SC 1] Between 28 And
40) And ([AT 1] Between 28 And 40)) Or ([BC 1] Between 60 And 72)

Any thoughts?

Thanks,

Duane Hookom said:
I am not sure how to get the conditional formatting to work. I can't "play"
with your expressions (or even see them) from my PC :)

You can use code in the On Format event of your report section to modify
formatting.
 

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