Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] Gauge Chart addition options (Box and label)
Go
New
Search
Notify
Tools
Reply
  
[CLOSED] Gauge Chart addition options (Box and label)
 Login/Join
 
Gold member
posted
Hi,

I have a gauge chart and it is working good with basic option. below is my code.
Gauge is showing in 65, and 65 I am displaying in bottom right. here I need to box the value and to add a label on bottom of that. I dont see any option in 8105m version.

Any help please!!!

 
DEFINE FILE CAR
GAUGE_CHRT/D12.2 = 65;
END

-*Do not delete or modify the comments above
ENGINE INT CACHE SET ON
-DEFAULTH &WF_STYLE_UNITS='PIXELS';
-DEFAULTH &WF_STYLE_HEIGHT='405.0';
-DEFAULTH &WF_STYLE_WIDTH='770.0';
-DEFAULTH &WF_TITLE='WebFOCUS Report';
GRAPH FILE car
-* Created by Info Assist for Graph
SUM CAR.BODY.DEALER_COST NOPRINT
GAUGE_CHRT
WHERE RECORDLIMIT EQ 1
ON GRAPH PCHOLD FORMAT JSCHART
ON GRAPH SET VZERO OFF
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET GRWIDTH 1
ON GRAPH SET UNITS &WF_STYLE_UNITS
ON GRAPH SET HAXIS &WF_STYLE_WIDTH
ON GRAPH SET VAXIS &WF_STYLE_HEIGHT
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 0
ON GRAPH SET GRXAXIS 0
ON GRAPH SET LOOKGRAPH GAUGE1
ON GRAPH SET AUTOFIT ON
ON GRAPH SET STYLE *
*GRAPH_SCRIPT
setPieDepth(0);
setPieTilt(0);
setDepthRadius(0);
setCurveFitEquationDisplay(false);
setPlace(true);
*END
INCLUDE=IBFS:/FILE/IBI_HTML_DIR/javaassist/intl/EN/ENIADefault_combine.sty,$
TYPE=REPORT, TITLETEXT=&WF_TITLE.QUOTEDSTRING, $
*GRAPH_SCRIPT
setReportParsingErrors(false);
setSelectionEnableMove(false);
setPiesPerRow(1);
setDisplay(getGaugeTitle(),false);
setTextFormatPreset(getGaugeValue(),1);
setFillColor(getChartBackground(),new Color(0,0,0,0));
setTransparentBorderColor(getChartBackground(),true);
setScaleMinAuto(getY1Axis(),false);
setScaleMax(getY1Axis(),100.0);
setScaleMaxAuto(getY1Axis(),false);
setGaugeBandMax(getGaugeBand1(),&CUTOVER);
setFontSizeAbsolute(getGaugeValue(),true);
setAutofit(getGaugeValue(),false);
setPlaceResize(getGaugeValue(),0);
setBorderColor(getGaugeBand2(),new Color(0,128,0));
setGaugeBandMax(getGaugeBand2(),100.0);
setFontName(getGaugeValue(),"ARIAL");
setGaugeBandMin(getGaugeBand2(),65.0);
setGaugeColorCenterByQuality(false);
setGaugeStartAngle(120.0);
setGaugeBackgroundStyle(0);

-IF &WARR_EXCE.EVAL GT 65 THEN GOTO :Skip_green;
setFillColor(getGaugeValue(),new Color(255,0,0));
-GOTO :Skip;
-:Skip_green
setFillColor(getGaugeValue(),new Color(0,128,0));
-:Skip

setDisplay(getGaugeValue(),true);
setGaugeStopAngle(340.0);
setFontSizeInPoints(getGaugeValue(),12);
setTextFormatPreset(getY1Label(),1);
setFontName(getY1Label(),"ARIAL BLACK");
setFillColor(getY1Label(),new Color(0,0,0));
setFontSizeAbsolute(getY1Label(),true);
setAutofit(getY1Label(),false);
setFontSizeInPoints(getY1Label(),10);
setPlaceResize(getY1Label(),0);
setGaugeMajorAutoStep(true);
setGaugeRelativeInnerRadius(0.3);
setGaugeMinorAutoStep(true);
setBorderColor(getGaugeMajorTick(),new Color(255,255,255));
setBorderColor(getGaugeMinorTick(),new Color(192,192,192));
setGaugeBandMax(getGaugeBand5(),150.0);
setGaugeBandMin(getGaugeBand4(),120.0);
setGaugeBandMin(getGaugeBand3(),100.0);
setGaugeBandMin(getGaugeBand5(),140.0);
setGaugeBandMax(getGaugeBand4(),130.0);
setGaugeBandMax(getGaugeBand3(),110.0);
setDisplay(getGaugeBand4(),true);
setFillColor(getGaugeBand2(),new Color(0,128,0));
setDisplay(getGaugeBand5(),true);
setDisplay(getGaugeBand3(),true);
setGaugeRelativeThickness(0.03);
*END
*GRAPH_JS
gaugeProperties: {
    axisMinorTickLength: '10%'},
yaxis: {
-*   minorGrid: {
-*      lineStyle: {width: 2,color: 'brown',dash: '2 2'}
-*   },
      intervalMode: 'interval',
      intervalValue: 10
}
*END

ENDSTYLE
END
-RUN
 

This message has been edited. Last edited by: FP Mod Chuck,


8202, 8105M, 7.7.03
 
Posts: 79 | Registered: June 12, 2012Reply With QuoteReport This Post
Virtuoso
posted Hide Post
Dev

I don't see a way "Out of the Box" to do what you are asking, it may take some custom Java Script which I have no expertise with...


Thank you for using Focal Point!

Chuck Wolff - Focal Point Moderator
WebFOCUS 7x and 8x, Windows, Linux All output Formats
 
Posts: 1746 | Location: Customer Support | Registered: April 12, 2005Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] Gauge Chart addition options (Box and label)

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.