Hello All,
I'm writing because i'm having an issue. I would like to format two cells using VBA. It is the basic if greater than less than argument with the light green/red background and dark green/red text if true or not. But because of how I have set up my cells, I have a separate cell next to the cell containing numbers, and i want to format that as well, and since it's text, i'm having a hard time. Basically if there was a way to match the conditional formatting of another cell that is what i want to do. I feel i've done a bad job explaining this, so i'll attach the sheet i'm trying to build.
Thank you for any help,
DarkF1ame
Last edited by DarkF1ame; 10-31-2011 at 01:32 PM.
Hi Darkflame,
You can use Conditional Formatting for this; no need for VBA.
1. Select C43:F43 and click Conditional Formatting > New Rule...
2. Select 'Use a formula to determine which cells to format'
3. Beneath 'Format values where this formula is true:', type the formula
=$C43>$F43
4. Click the Format... button and choose your Font/Fill color.
5. Click OK twice to return to worksheet.
6. With C43:F43 still selected, repeat the process but for the formula use:
=$C43<$F43
Hope that helps!
This worked and does just what I want to. Thank you so much Paul. +1
If you are satisfied with the solution(s) provided, please mark your thread as Solved.
How to mark a thread Solved
Go to the first post
Click edit
Click Go Advanced
Just below the word Title you will see a dropdown with the word No prefix.
Change to Solved
Click Save
“To sin by silence when they should protest makes cowards of men.” ~ Abraham Lincoln
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks