Format?

JOEE1979

Active Member
Joined
Dec 18, 2022
Messages
292
Office Version
  1. 365
Platform
  1. Windows
is it possible to have the "hours" column be grayed out unless "OT" or "Rover" is in the reason column?
I need this to be running the whole time, not just when someone runs a macro.
I hope I'm making sense.

Thank you



Shift Update.xlsm
KLM
970Attendance
971
972ReasonEmployeeHours
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
Shift Update
Cells with Conditional Formatting
CellConditionCell FormatStop If True
H973:M992Expression=MOD(ROW(),2)=0textNO
Cells with Data Validation
CellAllowCriteria
K973:K992List=Reason
L973:L992List=Employee
 

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"
You would just add another level of Conditional Formatting, and give it precedence over your current Conditional Formatting.
Your formula rule would look something like:
Excel Formula:
=AND(K973<>"OT",K973<>"Rover")
and choose the gray fill color.
 
Upvote 0
Solution
You could use more conditional formatting in column M. See below example.

Book1
KLM
970Attendance
971
972ReasonEmployeeHours
973OT
974Rover
975nothing
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
Sheet2
Cells with Conditional Formatting
CellConditionCell FormatStop If True
M973:M993Expression=OR(K973="OT",K973="Rover")textNO
K973:M992Expression=MOD(ROW(),2)=0textNO
 
Upvote 0
You are welcome.
Glad we were able to help.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,180
Members
453,021
Latest member
Justyna P

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