SHOW/HIDE ADD BUTTON ON A SLICE

Hi all,

I have a slice containing a list of record... every week this list must contain only one record per user.

How could I hide the ADD button on the slice when a user has already inserted his record ?

I tried with this expression in Behavior section (Only if this condition is true), but it doesn't work:

NOT(CONTAINS(SELECT(SliceA[USERNAME], TRUE), SELECT(Users[USERNAME], USEREMAIL()=[EMAIL])))

Thanks

Solved Solved
0 3 210
1 ACCEPTED SOLUTION

Thank you, In this slice expression, there does not seem to be any reference to date value that denotes the current week. You may want to add that.

Anyway, in the "Add " action of the table, please enter the below expression in the behavior setting of "only if this condition is true". Please replace "Slice Name" with actual slice name you have.

Suvrutt_Gurjar_0-1682005021731.png

 

The approach presumes the summary view is based on the slice.

View solution in original post

3 REPLIES 3


@dennis35 wrote:

I have a slice containing a list of record... every week this list must contain only one record per user.


For better response on feasibility of a solution, you may want to elaborate  on the slice composition.

If there are 10 users, will there be 10 records per week in the slice and how many weeks of records will be there in the slice- all weeks of current year, all weeks of the current month or only current month and so on. 

And will each user see only her/his owned record(s) and if so, how are you implementing this segregation by user currently.

It's right... in this slice every user will see only the own record of the current week. There are other slice that will show the previous week and the quarterly period.

The segregation is applied with a Users Table and an expression with CONTAINS such as CONTAINS(SELECT(Users[USERNAME], USEREMAIL()=[EMAIL]),[USERNAME]))

Thank you, In this slice expression, there does not seem to be any reference to date value that denotes the current week. You may want to add that.

Anyway, in the "Add " action of the table, please enter the below expression in the behavior setting of "only if this condition is true". Please replace "Slice Name" with actual slice name you have.

Suvrutt_Gurjar_0-1682005021731.png

 

The approach presumes the summary view is based on the slice.

Top Labels in this Space