I have created legends that appear with 2 decimal places in the client, but when published they show 30+ decimals! Could you please tell me how to truncate the webview to only show 2 decimals? The custom legend is: approvals.SRCNAME Approvals - approvals.APRVCNT ( approvals.APRV% %)
the attached picture should show : Approvals - 13,120 (97.54%) but shows: Approvals -13,120 (97.XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX%)
I am no expert on Regex syntax, but I think a regex in the legend area should work and might allow you to limit the characters showing there. If I find any good examples of this I will be sure to send them you way. If you do design a good regex for this purpose, it would be great if you shared it here.
One other option is to add a calculated field to the display (Hidden from the regular graph, but select that in the legend portion). Let me know if these tips were enough to help you try an approach, or whether you need more advice.
Create a new custom field on the display and apply the regex to the particular field there. Then use that field in the legend instead. (It doesn't need to be the field plotted on the graph that you use in the legend)
Online Help topic on Calculated Fields: http://help.prognosis.com/dr/Prognosis_11-2/mergedProjects/System_Functions/HTML_Files/Displays/Displays-CalculatedFields.htm?zoom_highlight=calculated+fields
Below is an example of adding an extra field for the regex Note: If I get some time, I'll see if the legend input box allows regex there too.
I have had this question asked earlier internally and what worked for me was to create a 'Numeric' user defined field that uses regex to only extract 2 decimal places precision out of the field. Interesting enough, it was for payments records.
So if you create a new user def field and show it in the pie and the legend, you should be good.