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     [CLOSED] bar graph column name order

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] bar graph column name order
 Login/Join
 
Platinum Member
posted
In my example below the colors of the bars will not change colors correctly when I use the across statement, but it does work if I use the By field. I have to use the across columns statement because the order of the countrys must be in this format. How can I get the colors to changes on the bars correctly and maintain the country order that I need?

 DEFINE FILE CAR
SALES/D10=SALES/1000;
END
GRAPH FILE CAR
SUM SALES AS 'Sales for'
-*BY COUNTRY
ACROSS COUNTRY AS ''
COLUMNS 'W GERMANY' AND 'JAPAN' AND 'ITALY' AND 'FRANCE' AND 'ENGLAND'  
ON GRAPH SET LOOKGRAPH BAR
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 GRAPHSTYLE *
setLegendDisplay(false);
setGaugeBackgroundStyle(7);
setMarkerDisplay(true);
setConnectLineMarkers(false);
setConnectScatterMarkers(false);
setO1LabelDisplay(true);
setO1AxisSide(0);
setO1MajorGridDisplay(true);
setO1MajorGridStyle(0);
setO1MinorGridDisplay(false);
setAxisAssignment(0,0);
setSeriesType(0,0);
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,
$
DEFMACRO=COND0001,
MACTYPE=RULE,
WHEN=SALES LT 80,
$
DEFMACRO=COND0002,
MACTYPE=RULE,
WHEN=SALES GT 80,
$
DEFMACRO=COND0003,
MACTYPE=RULE,
WHEN=SALES LT 50,
$
TYPE=DATA,
COLOR='SILVER',
$
TYPE=DATA,
COLOR='YELLOW',
MACRO=COND0003,
$
TYPE=DATA,
COLOR='LIME',
MACRO=COND0002,
$
TYPE=DATA,
COLOR='RED',
MACRO=COND0001,
$

ENDSTYLE
END



 

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


Prod: WebFocus 7.7.3 Win 2003
Dev: WebFocus 7.7.3 Win 2003
 
Posts: 116 | Registered: April 23, 2007Report This Post
Guru
posted Hide Post
Donald

have you tried using BY and LOKGRAPH VBAR?

Håkan


WebFOCUS DS 8.0.06/08 DS/AS
WebFOCUS RS 8.0.08 (Linux/IBM i)
WebFOCUS Client 8.0.06 (Linux)
 
Posts: 319 | Location: Stockholm, Sweden | Registered: February 04, 2004Report This Post
Virtuoso
posted Hide Post
Please run the following code. It may be helpful for you to find a solution:
DEFINE FILE CAR
SALES/D10=SALES/1000;
SORTCOUNTRY/A25 = DECODE COUNTRY('W GERMANY' '    W GERMANY'
                                 'JAPAN'     '   JAPAN'
                                 'ITALY'     '  ITALY'
                                 'FRANCE'    ' FRANCE'
                                 'ENGLAND'   'ENGLAND' );
END
GRAPH FILE CAR
SUM CAR.BODY.SALES AS 'Sales for'
BY SORTCOUNTRY AS 'Country'
ON GRAPH PCHOLD FORMAT PNG
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET VZERO ON
ON GRAPH SET HAXIS 770
ON GRAPH SET VAXIS 405
ON GRAPH SET UNITS PIXELS
ON GRAPH SET LOOKGRAPH VBAR
ON GRAPH SET BARNUMB OFF
ON GRAPH SET 3D OFF
ON GRAPH SET GRID ON
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 0
ON GRAPH SET GRXAXIS 1
ON GRAPH SET GRAPHSTYLE *
setTemplateFile("");
setReportParsingErrors(false);
setSelectionEnableMove(false);
setDepthRadius(5); 
setTransparentBorderColor(getChartBackground(),true); 
setTransparentBorderColor(getSeries(0),true);
setTransparentBorderColor(getSeries(1),true);
setTransparentBorderColor(getSeries(2),true);
setTransparentBorderColor(getSeries(3),true);
setTransparentBorderColor(getSeries(4),true);
setTransparentBorderColor(getSeries(5),true);
setTransparentBorderColor(getSeries(6),true);
setTransparentBorderColor(getSeries(7),true);
setTransparentBorderColor(getSeries(8),true);
setTransparentBorderColor(getSeries(9),true);
setTransparentBorderColor(getSeries(10),true);
setLegendDisplay(false);
setGaugeBackgroundStyle(7);
setMarkerDisplay(true);
setConnectLineMarkers(false);
setConnectScatterMarkers(false);
setO1LabelDisplay(true);
setO1AxisSide(0);
setO1MajorGridDisplay(true);
setO1MajorGridStyle(0);
setO1MinorGridDisplay(false);
setAxisAssignment(0,0);
setSeriesType(0,0);
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 *
DEFMACRO=COND0001, WHEN=N2 LE 50, $
DEFMACRO=COND0002, WHEN=N2 LT 80, $
DEFMACRO=COND0003, WHEN=N2 GE 80, $
TYPE=REPORT, FONT='ARIAL', SIZE=10, STYLE=NORMAL, $
TYPE=DATA, COLOR=RGB(192 192 192), $
TYPE=DATA, MACRO=COND0001, COLOR=RGB(255 0 0), $
TYPE=DATA, MACRO=COND0002, COLOR=RGB(0 255 0), $
TYPE=DATA, MACRO=COND0003, COLOR=RGB(255 255 0), $
ENDSTYLE
END
Hope this helps ...


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report 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     [CLOSED] bar graph column name order

Copyright © 1996-2020 Information Builders