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] Can you have only one COMPONENT using the COMPOUND LAYOUT command?

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Can you have only one COMPONENT using the COMPOUND LAYOUT command?
 Login/Join
 
Member
posted
Hello All,

This has stumped me for a day now so I broke down and re-created the issue using the CAR file and hopefully someone will have either a solution or a work-around.

I have a report that allows the user to choose to print only one graph or up to 21 graphs in a PDF using the Compound Layout command. It also includes a few excel files with detail data. Both the PDF and the Excel files come together in a TOC type format using the '-TYPE WEBFOCUS CGIVAR IBIWF_mreports=INDEX'. My issue rears it's ugly head when the user only chooses one graph. The Compound Layout and the TOC stop playing nice!

The first set of code below uses the car file that creates two graphs, side by side, as a PDF and then creates an Excel file with the car file detail. You will notice that it has two components (graph1 & graph2) in the Compound.

In the second set of code below, you will notice that I eliminated the second component, both in the Compound Layout section and the component section below. When I do this and run it, the graph pdf is fine but the Detail section now shows up as a PDF instead of Excel.

I think my issue is that the Compund Layout doesn't like it when my user only has one component(graph1 only) and just includes the next report in PDF because that's what the Compound Layout is made to do, Compound reports. But in the case when my user only wants one graph, I will always only have one component.

Is there any way to get this to work still using the Compound Layout Command when I only have one component? If not, is there a way to get the one graph to appear in the same place in a pdf just like I'm using the Compound Layout Command (Top Left Corner, Landscape,etc....) and then have the Detail still be an Excel File and still use the TOC?

My real report actually has 3 seperate pdfs and 3 Excel files that work great using my current code. I just wasn't expecting an issue to arise when only one graphs was chosen.

Any help would be greatly appreciated!

Keith



First Set of Code (With Two Components)

SET COMPOUND =ON
SET HTMLARCHIVE=ON
COMPOUND LAYOUT PCHOLD FORMAT PDF
SECTION=S1, LAYOUT=ON,MERGE=ON, ORIENTATION=LANDSCAPE, PAGESIZE=Letter, $
PAGELAYOUT=1,TOPMARGIN=0.05,$
COMPONENT='graph1', POSITION=(0.35 0.05), DIMENSION=(5 4), $
COMPONENT='graph2', POSITION=(+5.35 0.05), DIMENSION=(5 4), RELATIVE-TO='graph1',RELATIVE-POINT=TOP-RIGHT,POSITION-POINT=TOP-RIGHT, $
END


SET COMPONENT='graph1'
GRAPH FILE CAR
SUM SUM.CAR.BODY.RETAIL_COST
ACROSS CAR.ORIGIN.COUNTRY
ON GRAPH SET LOOKGRAPH PIEMULTI
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 TABLE PCHOLD FORMAT PDF
ON GRAPH SET GRAPHSTYLE *
setMarkerDisplay(true);
setConnectLineMarkers(false);
setConnectScatterMarkers(false);
setO1LabelDisplay(true);
setO1AxisSide(0);
setO1MajorGridDisplay(true);
setO1MajorGridStyle(0);
setO1MinorGridDisplay(false);
setAxisAssignment(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 *
$
ENDSTYLE
END


SET COMPONENT='graph2'
GRAPH FILE CAR
SUM SUM.CAR.BODY.DEALER_COST
ACROSS CAR.ORIGIN.COUNTRY
ON GRAPH SET LOOKGRAPH PIEMULTI
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 TABLE PCHOLD FORMAT PDF
ON GRAPH SET GRAPHSTYLE *
setMarkerDisplay(true);
setConnectLineMarkers(false);
setConnectScatterMarkers(false);
setO1LabelDisplay(true);
setO1AxisSide(0);
setO1MajorGridDisplay(true);
setO1MajorGridStyle(0);
setO1MinorGridDisplay(false);
setAxisAssignment(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 *
$
ENDSTYLE
END

COMPOUND END


-TYPE WEBFOCUS CGIVAR IBIWF_mreports=INDEX
-TYPE WEBFOCUS CGIVAR IBIWF_index = OFF
-TYPE WEBFOCUS CGIVAR IBIWF_mprefix=Car Graphs
-RUN



TABLE FILE CAR
PRINT *
ON TABLE PCHOLD FORMAT EXL2K
END


-TYPE WEBFOCUS CGIVAR IBIWF_mprefix=Car Excel Detail
-RUN



Second Set of Code (Only One Component)

SET COMPOUND =ON
SET HTMLARCHIVE=ON
COMPOUND LAYOUT PCHOLD FORMAT PDF
SECTION=S1, LAYOUT=ON,MERGE=ON, ORIENTATION=LANDSCAPE, PAGESIZE=Letter, $
PAGELAYOUT=1,TOPMARGIN=0.05,$
COMPONENT='graph1', POSITION=(0.35 0.05), DIMENSION=(5 4), $
END


SET COMPONENT='graph1'
GRAPH FILE CAR
SUM SUM.CAR.BODY.RETAIL_COST
ACROSS CAR.ORIGIN.COUNTRY
ON GRAPH SET LOOKGRAPH PIEMULTI
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 TABLE PCHOLD FORMAT PDF
ON GRAPH SET GRAPHSTYLE *
setMarkerDisplay(true);
setConnectLineMarkers(false);
setConnectScatterMarkers(false);
setO1LabelDisplay(true);
setO1AxisSide(0);
setO1MajorGridDisplay(true);
setO1MajorGridStyle(0);
setO1MinorGridDisplay(false);
setAxisAssignment(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 *
$
ENDSTYLE
END



COMPOUND END


-TYPE WEBFOCUS CGIVAR IBIWF_mreports=INDEX
-TYPE WEBFOCUS CGIVAR IBIWF_index = OFF
-TYPE WEBFOCUS CGIVAR IBIWF_mprefix=Car Graphs
-RUN



TABLE FILE CAR
PRINT *
ON TABLE PCHOLD FORMAT EXL2K
END


-TYPE WEBFOCUS CGIVAR IBIWF_mprefix=Car Excel Detail
-RUN

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


WebFOCUS 8.104
Windows, All Outputs
 
Posts: 28 | Location: Holland, MI USA | Registered: September 30, 2010Report This Post
<JG>
posted
Simple solution
If only one chart is chosen then insert a dummy chart where everything is set to white.
 
Report 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] Can you have only one COMPONENT using the COMPOUND LAYOUT command?

Copyright © 1996-2020 Information Builders