Monday 15 February 2010

excel - How do I do Conditional formatting on Macro -


I've got a spreadsheet where a user is opting for a job title from the drop down list and according to that job title something Special cells are highlighted with appropriate training courses.

The job title chosen for example is column B6 Highlight column M6 R6S6T6 (the same line) is for the yellow general manager

Does this mean?

If a different job title will need to highlight different cells, but I just want to get the basics already.

You can do this without a macro, if you can access the dropdown list value from sources < / P>

Therefore, how do you do it:

Create a new column where you will mark with a x , which apply to those jobs. Recommended Training Course with the title of the column.

In that column, you can create a formula using the dropdown value. Example: If the value is programmer , then there will be a x in line with the VBA course . Otherwise, nothing lesson: "" .

In this way, you do not need to code for conditional formatting, just formatting based on this column, in which the X value.

You can retain another sheet of course (column) x jobs (rows) . In that table, you mark x for all the codes and courses.

And your formula will be based on this table instead of the text names.

Relation Table Examples:

  ABCDE 1 ---- Programmer Manager Cleaner Programming Teacher 2 VBA Xx3C #xx 4 People's Relax XX 5 MPS X Usage   

This table will help a lot with the formula for filling up the recommended training course column with the x values.

(Of course you may need to adjust this table according to your main table formatting, if the courses are in lines or columns, if you show an example of your sheet formatting, then this Reply can be updated better way)

No comments:

Post a Comment