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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
nish18_1990
Helper III
Helper III

How to show a message on empty chart space

Hi ,

 

I want to show a message on the chart that "data is not available" if the bar and line dual axis chart is empty . How can we do it in power bi ?

 

Thanks

 

15 REPLIES 15
v-sgandrathi
Community Support
Community Support

Hi @nish18_1990,

 

 

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).

Do not include sensitive information. Do not include anything that is unrelated to the issue or question.

Please show the expected outcome based on the sample data you provided.

How to provide sample data in the Power BI Forum - Microsoft Fabric Community

Thank you.

Hi @nish18_1990,


Just checking in to see if you had a chance to follow up on our earlier conversation. If you're still encountering the issue, please share the sample data so we can assist you with an accurate solution.

If you have any further questions, feel free to reach out anytime.

 

Thank you.

Hi @nish18_1990,

 

Just checking in to see if you had a chance to follow up on our earlier conversation. If you're still encountering the issue, please share the sample data so we can assist you with an accurate solution.

If you have any further questions, feel free to reach out anytime.

 

Thank you.

@nish18_1990  Hey,
You can create this measure to get required result

 

DataCheck = IF(COUNTROWS(YourDataTable) = 0, "Data is not available", "")

Replace YourDataTable with the actual table name you're using in Power BI.

I will add a card in dashboard

Go to the "Visualizations" pane and select the Card visual. Drag the DataCheck measure into the Values field of the Card visual.

 

I will also use overlay

- Place the card visual over the empty chart space to display the message when the chart is empty.
- Set the card's background transparent if preferred so it lays over the chart when displaying.

 

 

Thanks

Harish M

v-sgandrathi
Community Support
Community Support

Hi @nish18_1990,

Thank you @Shahid12523 @MasonMA and @MFelix for your response to the query.

Has your issue been resolved?
If the response provided by the community member addressed your query, could you please confirm? It helps us ensure that the solutions provided are effective and beneficial for everyone.

Thank you.

Shahid12523
Resident Rockstar
Resident Rockstar

No Data Message =
IF(
ISBLANK(SUM('Table'[Value])),
"Data is not available",
BLANK()
)

Put it in a Card visual, overlay it on the chart, and make the background transparent → shows the message only when chart is empty.

(Alternative: use the measure as the chart title to display the message.)

Shahed Shaikh
MasonMA
Resident Rockstar
Resident Rockstar

 

Hello @nish18_1990 

 

If your chart is simple like one measure, one axis, just summing values, 

Message =
IF(
    ISBLANK(SUM(Table[Amount])) || SUM(Table[Amount]) = 0,
    "Data is not available",
    BLANK()
)

If your chart has multiple categories or complex measures (MTD, YTD, ratios, etc.) and you want to detect the case “all points are blank”, replace it with the SUMX/ALLSELECT pattern.

 

Place a 'Card (new)' visual on report and set up 'Show blank as' to Empty. Remove Title, Label and border of this card visual so that when there's data on Bar chart visual the Card visual looks completely transparent. 

MasonMA_0-1756135443349.png

MasonMA_1-1756135617053.png

When there is no data on Bar chart visual, the Card visual will display the message. 

MasonMA_2-1756135633293.png

Hope this helps:) 

 

 

I did tried the calculation but its not working 

 

Data not available = IF([#OnTime] = 0,"no","no data")
 
nish18_1990_0-1756364648583.png

 

I am getting only "no" as text . Not sure why. For blank and zero ontime measure i am not getting the text . Ontime measure is count distinct count of id .

 

When [#OnTime] is blank, the condition [OnTime] = 0 evaluates as TRUE., so both 0 and blank go into the "no" branch and you dont see "no data".

 

Try adjusting your measure to 

Measure =
IF (
ISBLANK ( [#OnTime] ) || [#OnTime] = 0,
"Data is not available",
BLANK()
)

Also please share some sample data to better help other users see if the fix is simply changing the IF logic, or whether you really need the card-overlay trick to handle “empty chart.”

Could you please provide power bi file for reference.

Hi @nish18_1990 

 

Please see the file here

 

please attach the file as i am not able to access link

The feature of attaching a file directly is only available to Super Users. Mine is saved in google drive and given the global access. you should be able to access. 

MFelix
Super User
Super User

Hi @nish18_1990 ,

 

This depends on the setup of your chart and the calculations but you need to create a measure that get the null value with the current context for example:

 

Warning message = 
IF
(SUMX(ALLSELECT(Table[ColumninAxis]), [MeasureinValues]) = Blank(), "Data is not available")

 

the use this measure on a card or has title on your chart, but if you do the second one don't forget to add the text for the title:

Warning message = 
IF
(SUMX(ALLSELECT(Table[ColumninAxis]), [MeasureinValues]) = Blank(), "Data is not available", "This is the Title of the chart")

Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



my chart is bar and line chart combo and on x axis i have months and y i have measures one for bar and one for line . Could you please share power bi file for reference.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Kudoed Authors