Focal Point
[SOLVED] Suppressing data values inside the bar graph

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/8647016306

May 11, 2011, 12:59 AM
Vijuchaks
[SOLVED] Suppressing data values inside the bar graph
Hi guys,

I just wanted to know if there is any API or any other way to suppress data values inside a graph.My graph due to some calculations is showing the original value along with an extra '0' just some space below the original value.I want to remove that zero.

Thanks

This message has been edited. Last edited by: Kerry,


Version 765
Windows XP/sp2
May 11, 2011, 05:02 AM
FrankDutch
if you show us some code that might help a lot

did you try this line

ON GRAPH SET VZERO OFF




Frank

prod: WF 7.6.10 platform Windows,
databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7
test: WF 7.6.10 on the same platform and databases,IE7

May 11, 2011, 05:18 AM
Vijuchaks
I will post the code here
GRAPH FILE PROGRAM_RPT3
PRINT RATING_1
RATING_2
RATING_3
RATING_4
BY PROGRAM
BY REGION
WHERE YEAR EQ '&DEF';
WHERE REGION EQ &listbox1;
ON GRAPH PCHOLD AS HOLD FORMAT PNG
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 0
ON GRAPH SET GRXAXIS 2
ON GRAPH SET HAXIS 2000
ON GRAPH SET VAXIS 1000
ON GRAPH SET UNITS PIXELS
ON GRAPH SET LOOKGRAPH VBRSTK1
ON GRAPH SET GRAPHSTYLE *
setTemplateFile("/images/tdg/template/IBISouthWestern.txt");
setReportParsingErrors(false);
setSelectionEnableMove(false);
setPlace(true);
setDepthRadius(5);
setTransparentBorderColor(getChartBackground(),true);
setDisplay(getDataTextStackedTotalOnTop(), false);
setDataTextDisplay (true);
setDisplay(getDataText(0), true);
setDisplay(getDataText(1), true);
setDisplay(getDataText(2), true);
-*setDisplay(getDataText(2), false);
setMarkerDisplay(true);
-*setStackedDataValueSum(false);
setDataTextPosition(3);

ENDSTYLE
ON GRAPH SET STYLE *
ENDSTYLE
END

Here RATING_1, RATING_2 RATING_3 are appearing as a single stacked bar while RATING_4 is appearing as a single bar side to the stacked one

Thanks


Version 765
Windows XP/sp2
May 23, 2011, 02:34 PM
Kerry
Hi Vijuchaks,

Has this issue been resolved? Many thanks for others' input.

Here is the suggestion from our technicals:
If the data is displaying as datatext ( always displays) then the following API command will prevent display
setDataTextDisplay(false);

If you only see the data when the mouse is placed over the bar, tooltip display must be turned off and the API command below should work
setToolTipDisplay(false);

Cheers,

Kerry


Kerry Zhan
Focal Point Moderator
Information Builders, Inc.
May 24, 2011, 05:04 AM
Vijuchaks
Thanks Kerry
The issue did resolve, however, it was by using another API setFillMissingData(0);
Here as per the requirement, I needed to create a single bar besides a stacked bar.Stacked bar had three values RATING_1,RATING_2 and RATING_3
while single bar had only RATING_4.Hence in order to obtain that we had to set other three ratings as 0 in single bar which was showing up as zero.This was removed by following code
RATING_1/I4 MISSING ON = IF RATING_1 NE 0 THEN RATING_1 ELSE MISSING;
RATING_2/I4 MISSING ON = IF RATING_2 NE 0 THEN RATING_2 ELSE MISSING;
RATING_3/I4 MISSING ON = IF RATING_3 NE 0 THEN RATING_3 ELSE MISSING;
and then setting the API.
Thanks everybody for their help


Version 765
Windows XP/sp2