In the attached file I would like to highlight all Stores in the selected (via the UserForm) Manager's Region. I can't seem to figure out how to highlight one column to the right of the value returned by VLookup.
Thank you.
In the attached file I would like to highlight all Stores in the selected (via the UserForm) Manager's Region. I can't seem to figure out how to highlight one column to the right of the value returned by VLookup.
Thank you.
Last edited by tommy_m; 09-16-2012 at 04:56 PM. Reason: Solved: http://www.excelforum.com/excel-programming-vba-macros/860789-conditional-formatting-offset.html?p=2934401&viewfull=1#post2934401
Hi, tommy_m,
if you compare the Value of say B3 to South you will find no match. So you need to change the Conditional Formatting from Cell Value to Expression:
You might even think about using different colour codes for the managers, i.e.Please Login or Register to view this content.
Ciao,Please Login or Register to view this content.
Holger
Use Code-Tags for showing your code: [code] Your Code here [/code]
Please mark your question Solved if there has been offered a solution that works fine for you
Holger,
Thank you for your reply. This worked perfectly in Excel 2010, but does not highlight anything in Excel 2003. I tried manually defining the ranges, but it did not have the intended effect. The attached file has a few more tables to more accurately represent what I'm working with.
- Tommy
Hi, Tommy,
If you change a code that works please take care that you copy all relevant parts (you missed the assignment of the cells as being absolute in column, and I usually work with multiple areas a little bit different):...but does not highlight anything in Excel 2003
Your code:
Please Login or Register to view this content.
Tested in Excel 2000 - but I would break down the single areas as otherwise only the value in Column A is taken for to colour the cells but not the value in the column next to the colour. This would mean work with a loop for the three areas instead of marking one great area. Can you do that on your own?Please Login or Register to view this content.
Ciao,
Holger
Last edited by HaHoBe; 09-16-2012 at 03:10 PM. Reason: just realized the need of a loop for correct output, changes in italic
Holger,
Thank you very much for your help on this! The following code accomplishes what I set out to do:
I assume there is a more elegant way to accomplish this, but the above code is functional and I'm happy with that!Please Login or Register to view this content.
- Tommy
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks