Basic NOOB VBA question (Conditional Formating)

Leadparsons

New Member
Joined
Mar 11, 2015
Messages
44
I all,

out of all the code I have written in to my DB and had help on I seem to have hit a basic one that I can not sort.

I have two fields 1 and 2, I want to put conditional formatting on no 2 to highlight (in green) if no 1 is the same as no 2 or if not the same highlight (in red).

I now it has something to do with IIF but I can only get that to work on one field if it is true.

Help, my brain seems to have turned to mush.
 

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand
I now it has something to do with IIF but I can only get that to work on one field if it is true.
Did you Conditionally Format BOTH fields using your formula?

Can you post your formula?
 
Upvote 0
For equal, your Conditional Formula would just be:
Code:
=[Cell1]=[Cell2]

For not equal, your Conditional Formula would just be:
Code:
=[Cell1]<>[Cell2]

If you need more help than that, list all the actual details of an example (what your cell addresses are, what the values are, etc).
 
Upvote 0
I am working in Access ! It does not accept the code.

Field 1 is called IA_Value field 2 is called LOI_Amount, so if the two match I want field 2 to be highlighted.
 
Upvote 0
I am working in Access ! It does not accept the code.
Whoops, I confused my Access and Excel. Sorry about that. With the gap in time between replies, I forgot where I was.

Glad you got it figured out.
 
Upvote 0

Forum statistics

Threads
1,221,848
Messages
6,162,419
Members
451,765
Latest member
craigvan888

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top