Forum Discussion
rschaudhr
5 years agoResolver II
Default value when no filter selected
I have a case where I have the following data: There is a slicer based on the department. When Finance is selected in the slicer, another visual will display the comments related to finance...
- 5 years ago
Hi rschaudhr,
You should use a measure similar to the one below:
Comments selection = IF ( ISFILTERED ( CommentsTable[Department] ), SELECTEDVALUE ( CommentsTable[Comments] ), CALCULATE ( SELECTEDVALUE ( CommentsTable[Comments] ), FILTER ( ALL ( CommentsTable[Department], CommentsTable[Comments] ), CommentsTable[Department] = "Investments" ) ) )
Anonymous
5 years agoNot applicable
Hi rschaudhr ,
You will need to create a independed department table and use it as slicer.
slicer = DISTINCT('Table'[DEP])
Then create a measure as below and add it to visual filter.
Measure = IF(ISFILTERED(slicer[DEP]),IF(SELECTEDVALUE('Table'[DEP]) in VALUES(slicer[DEP]),1,0),IF(SELECTEDVALUE('Table'[DEP])="INV",1,0))
Best Regards,
Jay
- rschaudhr5 years agoResolver II
Anonymous , Thank you! This work very well.