Search code examples
google-sheetsconditional-formatting

Can I set conditional formatting based on cell which is located in same file but on other worksheet in google sheets?


I have two google worksheet one named sample1 and another sample2. I have value 2 in A1 of sample1, now can I check if sample2 A1 is equal to A1 of sample2 which should also be 2, if false, set color to red.


Solution

  • To use values from another page of the spreadsheet, in a custom conditional formatting function, use the function:

    INDIRECT()

    Additional Reference: Role of Indirect Function in Conditional Formatting in Google Sheets