Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
motleyts2
New Member

Make Slicer a Variable to add to Power Automate

Hello. I have a slicer that has Line of Business (LOB) values (i.e., Medicare, Medicaid, Commercial, etc). How can I make this slicer a dynamic variable to use in Power Automate? In Power Automate, the value in the slicer (let's say it's "Medicare") will be added to the File Name in the Create File to Sharepoint action.

 

In summary, I need assistance with making a slicer a dynamic value that updates the File Name in the Create File action. So, if the user chooses "Medicare" or another value in the slicer, this value will be updated in the File Name in Power Automate as "PowerBIData_[LOB]_DateTime". The end goal is to create a CSV file with a dynamic File Name that updates based on the slicer value.

 

Thank you.

1 ACCEPTED SOLUTION
christinepayton
Super User
Super User

Are you using the Power Automate visual, where you click the button to send it to PA? If that's what you're using, I would just put the field into the table visual so that when you click the button, whatever is selected in the slicer is sent along with the data to Power Automate by virtue of it also being in the table. If it's a single-select slicer, you can just get the first value with an expression on the Power Automate side. 

View solution in original post

2 REPLIES 2
christinepayton
Super User
Super User

Are you using the Power Automate visual, where you click the button to send it to PA? If that's what you're using, I would just put the field into the table visual so that when you click the button, whatever is selected in the slicer is sent along with the data to Power Automate by virtue of it also being in the table. If it's a single-select slicer, you can just get the first value with an expression on the Power Automate side. 

Thank you! I ended up creating a selected value of the slicer as a measure. Added the measure to the Power Automate flow values. Added a Compose action in the flow with the triggerbody expresssion. 

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.