I need to customize ''No data to display'' error message on my bar chart for no data available for current selection.So how can i change this error message ...Please any body help me on this.
in the General tab of the properties of the bar chart, there is a button in the bottom left named "Error messages" where you can customize the error messages shown in the chart.
Hope this helps!
Fei is right, the message cannot be changed. BUT fortunately you could produce a "calculation condition not fulfilled" condition which error message could be customized. E.g. I add the expression directly in the calculation condition. When it returns null, the condition is not fulfilled and I could make use of the custom error message box.
You can use a text box with your message to hide your graph when data is null.
Make a copy of bar graph in different sheet and convert that chart type from General tab to Straight Table.
After then you can use macro for this table (say CH16😞
ActiveDocument.Variables("v").SetContent cell.text, True
This will store the total (which is 0 whenever "no data to display" comes) of your expression in variable "v".Then you can use this v variable to show/hide your text box.
Hope this helps
Yes, you have to make some button to run macro. But to run this automatically on the basis of user selection , apply triggers (to Run macro) on all columns through which data of that table (CH16) changes.
Note: in my table cell(1,4) contains total. For getting this value , check "Expression total" instead of "No Total" under expression tab