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] Bar Graph - Change of Data Label Color
Go
New
Search
Notify
Tools
Reply
  
[CLOSED] Bar Graph - Change of Data Label Color
 Login/Join
 
Platinum Member
posted
Hello, I have below code with a CAR file. As per requirement, W GERMANY's bar color and series 1's data text colors are the same. So, data text is not visible inside "W GERMANY" bar. It is supposed to be in white color. I am not able to do it as WebFOCUS is only allowing to customize font for full series but not individual value of a series. Any suggestions are appreciated. Thank you.
 ENGINE INT CACHE SET ON
SET PAGE-NUM=NOLEAD
SET HTMLENCODE=ON
SET ARGRAPHENGINE=JSCHART
SET EMBEDHEADING=ON
SET GRAPHDEFAULT=OFF
DEFINE FILE CAR
FLD_FLAG/A20 = 'W GERMANY';
END
GRAPH FILE CAR
SUM
	SALES/D12M AS ''
	SEATS/I9 AS ''
BY FLD_FLAG AS '' NOPRINT
BY COUNTRY AS ''
ON GRAPH PCHOLD FORMAT PDF
ON GRAPH SET VZERO OFF
ON GRAPH SET GRWIDTH 1
ON GRAPH SET UNITS INCHES
ON GRAPH SET HAXIS 8
ON GRAPH SET VAXIS 6
ON GRAPH SET GRMERGE ON
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 0
ON GRAPH SET GRXAXIS 1
ON GRAPH SET LOOKGRAPH VBAR
ON GRAPH SET AUTOFIT ON
ON GRAPH SET STYLE *
*GRAPH_SCRIPT
setPieDepth(0);
setPieTilt(0);
setDepthRadius(0);
setCurveFitEquationDisplay(false);
setPlace(true);
setRiserWidth(60);
setReportParsingErrors(false);
setSelectionEnableMove(false);
*END
INCLUDE=IBFS:/FILE/IBI_HTML_DIR/ibi_themes/Warm.sty,$
TYPE=REPORT, PAGESIZE=LETTER, ORIENTATION=LANDSCAPE, $
DEFMACRO=COND0001, MACTYPE=RULE, COLOR=RGB(38 97 140), WHEN=N1 EQ N2, $
DEFMACRO=COND0002, MACTYPE=RULE, COLOR=RGB(208 214 219), WHEN=N1 NE N2, $
TYPE=DATA, COLUMN=N3, MACRO=COND0002, $
TYPE=DATA, COLUMN=N3, MACRO=COND0001, $
*GRAPH_SCRIPT
setSeriesType(0,1);
setSeriesType(1,2);
setDisplay(getLegendArea(),false);
setDataTextPosition(1);
setDataTextDisplay(true);
setDisplay(getDataText(0),true);
setFillColor(getDataText(0),new Color(18,48,76));
setDisplay(getDataText(1),true);
setFillColor(getDataText(1),new Color(38,97,140));
*END
ENDSTYLE
END 

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


WF 8.2.01 APP STUDIO
PDF,HTML,EXL2K,Active
 
Posts: 135 | Registered: July 21, 2011Reply With QuoteReport This Post
Guru
posted Hide Post
These two lines determine the colors for the Data labels, you have (0) as sales and (1) as seats for now.
quote:

setFillColor(getDataText(0),new Color(18,48,76));
setDisplay(getDataText(1),true);
setFillColor(getDataText(1),new Color(38,97,140));


If you change the above colors to 255,255,255 you'll see the difference.


-********************
Sandbox: 8206.10
Dev: 8201M
Prod:8009
-********************
 
Posts: 256 | Location: Houston,TX | Registered: June 11, 2004Reply With QuoteReport This Post
Platinum Member
posted Hide Post
That changes the color of full series. I am looking to change color of 1 value in a series.
quote:
Originally posted by vaayu:
These two lines determine the colors for the Data labels, you have (0) as sales and (1) as seats for now.
quote:

setFillColor(getDataText(0),new Color(18,48,76));
setDisplay(getDataText(1),true);
setFillColor(getDataText(1),new Color(38,97,140));


If you change the above colors to 255,255,255 you'll see the difference.


WF 8.2.01 APP STUDIO
PDF,HTML,EXL2K,Active
 
Posts: 135 | Registered: July 21, 2011Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] Bar Graph - Change of Data Label Color

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