Forum Discussion

spamitovic's avatar
spamitovic
Copper Contributor
Sep 06, 2020
Solved

Check the value of a function

Hi all,

 

I have a table that contains all current month days, the days are displayed on each column.

For example, in my B1 cell, I added the following function:

=DATE(Tableau2[Current year],Tableau2[Starting month],1)

Tableau2[Current year] = 2020 and Tableau2[Starting month] = 1 (January)

The cell C1 will contains 

=B1+1

What I need is, if the current day is saturday or sunday, then the cell will be disable or just the background will change. But my problem is that I can't check that with the function IF, I can't verify the value of B1 or C1.

My question is, how can I create a condition to check the value or the result of a function in a specific cell?

 

  • mtarler's avatar
    mtarler
    Sep 08, 2020

    spamitovic  The translation isn't very good but I think what you want is to add '$' in formula as so:

    =OR(WEEKDAY(C$3,2)=6,WEEKDAY(C$3,2)=7)

     

5 Replies

Resources