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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
somnath6309
Helper I
Helper I

How to Apply Parameter in Chart

Hi,

I wanted to add a Parameter in a Line Chart. The following Line Chart was created in Power BI Desktop:

somnath6309_0-1686666415221.png

It shows month wise "Sales", "Profit" and "Quantity" ( Quantity is shown in secondary Y axis).

Now, user may want to choose "Sales", "Profit" or "Quantity" from a Slicer and view the chart accordingly. For this reason I had created a PARAMETER called "ShowValueForChart" and created a the folloiwng slicer for the same:

somnath6309_1-1686666676729.png

the Table named "ShowValueForChart" is as follows:

 

somnath6309_2-1686667299807.png

I have also created a measure named Value Selection which captures the current selection from the slicer. Following is the code:

Value Selection = SELECTEDVALUE(ShowValueForChart[ShowValue Fields])
 
However, I am not able to conneect the Slicer to the Chart. Pls let me know what needs to be done to connect the Slicer and the chart so that the user can select "Sales" / "Profit" / "Quantiy" on his own and the chart shows the line graph accordingly. 
 
the Main data table named "Orders" and the snap shot of the same is as follows:
 
somnath6309_3-1686667929022.png

 

Pls let me know what needs to be done to get the desired result. 

 

Regards,

Somnath

 

 
 

 

 

 

 

 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @somnath6309 ,

 

According to your description, here are my steps you can follow as a solution.

(1) We can create three measures.

_Order qiantity = SUM('Table'[Order Qiantity])
_Profit = SUM('Table'[Profit])
_Sales = SUM('Table'[Sales])

(2) We can create a field parameter.

vtangjiemsft_0-1686796312302.png

(3) Then the result is as follows.

vtangjiemsft_1-1686796385793.pngvtangjiemsft_2-1686796410516.png

 

 

 

If the above one can't help you get the desired result, please provide some sample data in your tables (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. Thank you.

 

Best Regards,

Neeko Tang

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

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Hi @somnath6309 ,

 

According to your description, here are my steps you can follow as a solution.

(1) We can create three measures.

_Order qiantity = SUM('Table'[Order Qiantity])
_Profit = SUM('Table'[Profit])
_Sales = SUM('Table'[Sales])

(2) We can create a field parameter.

vtangjiemsft_0-1686796312302.png

(3) Then the result is as follows.

vtangjiemsft_1-1686796385793.pngvtangjiemsft_2-1686796410516.png

 

 

 

If the above one can't help you get the desired result, please provide some sample data in your tables (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. Thank you.

 

Best Regards,

Neeko Tang

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

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors