Applying conditional formating to make cells change color

L

leigh.maselli

I have a spreadsheet with a total amount, account number, account
name, and two different cash amounts. I want to set up a CF but I
need it in VBA because the information gets imported and erases the CF
otherwise. What I want is for the corresponding row in columns A, B,
C, D and E to change to red and bold if either of the values in Column
F and G are <0.

i.e.
Total Acct number Account Name Amount 1 Amount 2
1000.00 99 99-999 9999999 John Doe 1002.22 -2.22
1002.00 99 99-999 9999999 Jane Doe 1000.00 2.00
-1003.33 99 99-999 9999999 Jim Doe -1006.66
3.33


The first and last rows should be red and bolded. I can do it with
regular conditional formatting but I need code instead. Also the
account number is 3 columns
 
E

Earl Kiosterud

Leigh,

If you can use Data - Get External Data, it will import the data into the same worksheet
each time, and your conditional formatting will be kept. Data - Get External Data.
Navigate to your import file, and step through the Wizard. It works well. It reads all
kinds of files.
 

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