shade excel cells grey depending on another cells data?

comptechbranden

Registered User.
Local time
Today, 09:12
Joined
May 25, 2006
Messages
119
I am attempting to grey out cells that wont be used to enter data with some code. It should still allow one to enter data to those cells though just in case they need to for some odd reason.

I am thinking the code would flow such that, lets say... B2:B5000 = Project 1 or Project 2 or Project 3 or Project 4 then turn G2:L2 Light Gray IF not then leave alone.

Any help on some code for the cell or for the VBA section would be of great help. I am just getting used to VBA so if there is anything special about where it goes please include that.

Thanks for any help.
 
Is this on a Form? Because this smells like Excel to me, try the excel part of the board
 
Treason said:
Is this on a Form? Because this smells like Excel to me, try the excel part of the board

Smells like you don't know the answer. :) Well, its called conditional formatting if anyone wants to know.
 
comptechbranden said:
Smells like you don't know the answer. :) Well, its called conditional formatting if anyone wants to know.

My mistake.. Your terminology is misleading, Access uses records not cells. B2:B5000 sounds like a range in Excel and not records in Access. No I don't know the answer, but i am not sure if you are asking the right questions. Where are you applying conditional formatting? Table, Form or Report?
 
Wait are you automating excel through VBA? It even says excel in your post title. You gotta ask your question better. What else would you expect me to think?
 

Users who are viewing this thread

Back
Top Bottom