Forum Discussion
Filter Buttons
I have a report and one section of the report includes a table displaying comments and then a "Text Filter" visual to allow users to search the comments.
The report owner has now asked as well as the search box, would it be possible to have buttons with "Key Words" that will will filter the column table, such as "Huawei" and when the user presses the button, the table displays all rows with "Huawei" in it.
I will be searching and testing, but any advise/guideance would be grateful.
Thanks
StuartSmith To use the filter, you need to create a measure that connects it to your data, so for example:
SuggestedFilter = IF( CONTAINSSTRING( Table[Comments], SELECTEDVALUE(Slicer[SlicerColumn])) , 1, 0)
Then add this slicer to your table visual (and search box too if you want) and set to filter for only = 1 .
Note, this will only work for single selections in the chiclet. You may need more advanced DAX if it must work for multi-select.
Think i figured it out...
TEST_Key_Search_Word_Filter_Measure =VAR Key_Word = SELECTEDVALUE('Key Words'[Value])RETURN IF(CONTAINSSTRING(SELECTEDVALUE('Carrier Matrix'[OData__2_Contractcomments]),Key_Word),1,0)Does that look right?
9 Replies
- amitchandakSuper User
- StuartSmithPower Participant
Thanks, I am already using that visual, highlighted in "Red", but was hoping for a "Quick Filter" button (Green).
- StuartSmithPower Participant
I could use BookMarks, but Bookmarks dont keep filters if set and I know there is a tick box called "Data" to stop filters resetting, but was wondering if you could apply a single word filter to a button.