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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Vimalaanand
New Member

Execute settings on Report opening

Hi, 

 

I would prefer to execute a code or Dax to set slicers based on the person launching the report. 

 

So can you let me know if there is an option to execute any code on report opening?

 

Thanks 

1 ACCEPTED SOLUTION
mihart
Employee
Employee

Hi @Vimalaanand 

You could try using paginated report.  Prompt for username and then when report opens you can have slicers based on the person authenticated. 

 

"Add interactive features such as document maps, show/hide buttons, and drillthrough links to subreports and drillthrough reports. Use parameters and filters to filter data for customized views."

 

Here's a good article to get you started:  https://docs.microsoft.com/en-us/power-bi/paginated-reports/paginated-reports-report-builder-power-...

 

HTH,

Michele

View solution in original post

2 REPLIES 2
mihart
Employee
Employee

Hi @Vimalaanand 

You could try using paginated report.  Prompt for username and then when report opens you can have slicers based on the person authenticated. 

 

"Add interactive features such as document maps, show/hide buttons, and drillthrough links to subreports and drillthrough reports. Use parameters and filters to filter data for customized views."

 

Here's a good article to get you started:  https://docs.microsoft.com/en-us/power-bi/paginated-reports/paginated-reports-report-builder-power-...

 

HTH,

Michele

v-xuding-msft
Community Support
Community Support

Hi @Vimalaanand ,

 

What the results do you want? If you are trying to show the values of date while opening, you could use the relative date filter to filter slicer or use a relative date slicer directly. For more details, please take a good look at the document:

Creating a relative date slicer and filter in Power BI  

 

If you want to show other values, you could try to create a measure to show them. For slicers, there is not a option to set them show while opening.

 

If there can't work for you, please share a few screenshots to let us understand clearly.

 

 

Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

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.