Forum Discussion

ymt19's avatar
ymt19
Copper Contributor
Sep 13, 2022

Highlight or lock cells based on a date condition

I'm creating a resource capacity plan and I'm trying to lock or highlight (in grey) cells from columns K-Z depending on columns C and D. So for example project A starts in Sept 22 and ends in  Sept 23, I want cells K3 to be locked/highlighted as it is before the project start date and same for cells Y3 and Z3 as these are dates after the `project end date. Same for the rest of the rows. Is there any way of doing this?

 

 

2 Replies

  • ymt19 

    =(K$2<=EOMONTH($C3,-1))+(K$2>$D3)

    In order to highlight cells you can try this rule for conditional formatting.

    =$K$3:$Z$7

    This is the range the format applies to in the example.

  • NikolinoDE's avatar
    NikolinoDE
    Gold Contributor

    ymt19 

    Lock or unlock specific areas/cells of a protected worksheet

    By default, protecting a worksheet locks all cells so none of them are editable. To enable some cell editing, while leaving other cells locked, it's possible to unlock all the cells. You can lock only specific cells and ranges before you protect the worksheet and, optionally, enable specific users to edit only in specific ranges of a protected sheet.

    More informations will find in the upper link.

     

     

    NikolinoDE

    I know I don't know anything (Socrates

     

Resources