Conditional Format on copied worksheet stop working

L

Larry

I have a "template" worksheet, which I copy to other worksheets in VBA
using the Worksheet.Copy method.

The template worksheet has conditional formatting applied to many
cells. When the copy is made, the code then puts values into certain
cells based on a database query.

The strange thing is, the conditional formating does not always kick
in. The formatting just says things like "cell value is less than 1"
set color to red, that kind of thing.

When the copy and populating the data is complete, the value may have
a 1 but also have the color (it's supposed to be normal if it's 1 or
higher).

Is there something I need to do to activate or trigger the conditional
formatting? The formatting works, because if I go to that cell and
change it to 0, then back to 1, the color is fine. It's just not
working when the code copies the template and puts the data in cells.

Any ideas?

Thanks,
Larry

BTW, Excel XP and Windows XP
 
L

Larry

Hi Larry,

Try:

Tool | Options | Calculation | Automatic
Thanks, I have Automatic turned on and that doesn't help.

I also tried hitting the F9 button to cause it to calculate and that
didn't do it either.
 

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