Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Conditional Styling (Stacked Bar Graph)

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Conditional Styling (Stacked Bar Graph)
 Login/Join
 
Platinum Member
posted
I am trying to conditionally style the following code that is setup just like a report I am trying to create.
I want to be able to change the colors for each Car. Example would be in Japan and W Germany, how can I have BMW in W Germany be lets say "BLUE" instead of Pink??? This is easy when there are only two things to graph, but adding the third element has been difficult.
Thank you to anyone that could possibly help!



GRAPH FILE CAR
SUM CAR.BODY.SALES
ACROSS CAR.ORIGIN.COUNTRY
BY CAR.COMP.CAR
HEADING
""
ON GRAPH SET LOOKGRAPH VBRSTK1
ON GRAPH SET GRAPHEDIT SERVER
ON GRAPH SET BARNUMB OFF
ON GRAPH SET 3D OFF
ON GRAPH SET VZERO ON
ON GRAPH SET GRID ON
ON GRAPH SET GRMERGE ON
ON GRAPH PCHOLD FORMAT PNG
ON GRAPH SET GRAPHSTYLE *
setLegendMarkerPosition(4);
setMarkerDisplay(true);
setConnectLineMarkers(false);
setConnectScatterMarkers(false);
setO1LabelDisplay(true);
setO1AxisSide(0);
setO1MajorGridDisplay(true);
setO1MajorGridStyle(0);
setO1MinorGridDisplay(false);
setAxisAssignment(0,0);
setSeriesType(0,1);
setY1LabelDisplay(true);
setY1AxisSide(0);
setY1MajorGridDisplay(true);
setY1MajorGridStyle(0);
setY1MinorGridDisplay(false);
setTextFormatPreset(getY1Label(),-1);
setTextFormatPattern(getY1Label(),"#.##");
setPieFeelerTextDisplay(1);
setPieLabelDisplay(0);
setTextFormatPreset(getPieSliceLabel(),1);
setRiserBorderMode(1);
setSeriesDefaultTransparentBorderColor(true);
setUseSeriesBorderDefaults(true);
setLegendDisplay(true);
setFontSizeAbsolute(getY1Title(),true);
setFontSizeAbsolute(getY1Label(),true);
setFontSizeAbsolute(getY2Title(),true);
setFontSizeAbsolute(getY2Label(),true);
setFontSizeAbsolute(getO1Title(),true);
setPlace(true);
ENDSTYLE
ON GRAPH SET STYLE *
PAGESIZE='Letter',
LEFTMARGIN=0.250000,
RIGHTMARGIN=0.250000,
TOPMARGIN=0.250000,
BOTTOMMARGIN=0.250000,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
$
TYPE=REPORT,
GRID=OFF,
FONT='TIMES NEW ROMAN',
SIZE=10,
BACKCOLOR='NONE',
STYLE=NORMAL,
$
TYPE=HEADING,
LINE=1,
OBJECT=FIELD,
ITEM=1,
COLOR='BLACK',
$
ENDSTYLE
END

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


Currenly working @ Learning Circle Education Services
Previously worked @ Nationwide Insurance
Prod: WebFOCUS 7.6.11


Test: WebFOCUS 7.6.11


Dev: WebFOCUS 7.6.11
 
Posts: 125 | Location: Columbus, Ohio | Registered: March 31, 2006Report This Post
Expert
posted Hide Post
neuro,

Use the java to change the colour for a specific series -
setFillType(getSeries(0),1);
setSeriesFillColor(0,new Color(170,250,255));
setFillType(getSeries(1),1);
setSeriesFillColor(1,new Color(170,175,255));
setFillType(getSeries(2),1);
setSeriesFillColor(2,new Color(170,100,255));
setFillType(getSeries(3),1);
setSeriesFillColor(3,new Color(100,250,255));
setFillType(getSeries(4),1);
setSeriesFillColor(4,new Color(100,175,255));
setFillType(getSeries(5),1);
setSeriesFillColor(5,new Color(100,100,255));

You could, of course, use a variable instead of the rgb values.

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Platinum Member
posted Hide Post
You could try this one.....with your own RGB preferences

setFillColor(getSeries(0), new Color(0,0,255));
setFillColor(getSeries(1), new Color(0,255,0));
setFillColor(getSeries(2), new Color(255,0,255));
setFillColor(getSeries(3), new Color(255,255,0));
setFillColor(getSeries(4), new Color(255,0,0));
setFillColor(getSeries(5), new Color(255,165,0));
setFillColor(getSeries(6), new Color(255,192,203));
setFillColor(getSeries(7), new Color(0,255,255));
setFillColor(getSeries(8), new Color(206,0,54));
setFillColor(getSeries(9), new Color(255,239,0));
setFillColor(getSeries(10), new Color(0,152,82));
....
....
Goooooooooooooooood day !!


-------------------------------------------------------------------------------------------------
Blue Cross & Blue Shield of MS
WF.76-10 on (WS2003 + WebSphere) / EDA on z/OS + DB2 + MS-SQL
MRE, BID, Dev. Studio, Self-Service apps & a dash of fun !! Music
 
Posts: 218 | Location: Jackson, MS | Registered: October 31, 2006Report This Post
Platinum Member
posted Hide Post
Thank you this works great!


Currenly working @ Learning Circle Education Services
Previously worked @ Nationwide Insurance
Prod: WebFOCUS 7.6.11


Test: WebFOCUS 7.6.11


Dev: WebFOCUS 7.6.11
 
Posts: 125 | Location: Columbus, Ohio | Registered: March 31, 2006Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Conditional Styling (Stacked Bar Graph)

Copyright © 1996-2020 Information Builders