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.
-SET &ECHO=ALL;
-SET &R = RDUNIF('D4.2') * 10000;
-SET &APPFOLDER = 'baseapp/';
-SET &USERID = GETUSER('A8');
-SET &LC_USER = LOCASE(8, &USERID, 'A8');
-SET &GIF_FILE = &LC_USER || &R || '.jpg' ;
-SET &PATH = &APPFOLDER || &GIF_FILE;
APP FI GRAPH2 DISK &PATH
-RUN
GRAPH FILE CAR
HEADING CENTER
"TOTAL RETAIL COST BY COUNTRY"
" "
SUM RETAIL_COST AS ''
ACROSS COUNTRY
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET HAXIS 770
ON GRAPH SET VAXIS 405
ON GRAPH SET UNITS PIXELS
ON GRAPH SET LOOKGRAPH PIE
ON GRAPH SET GRMERGE ON
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 0
ON GRAPH SET GRXAXIS 2
ON GRAPH HOLD AS GRAPH2 FORMAT JPEG
ON GRAPH SET STYLE *
-*TYPE = DATA, FOCEXEC=app/CAR_DRILL(COUNTRY = A1), ACROSSCOLUMN=RETAIL_COST, TARGET=_blank, $
TYPE = REPORT, FONT=VERDANA, SIZE=9, $
TYPE = HEADING, FONT=VERDANA, SIZE=10, STYLE=BOLD, $
ENDSTYLE
ON GRAPH SET GRAPHSTYLE *
setTemplateFile("/images/tdg/template/IBISouthWestern.txt");
setFontName(getDataText(),"Verdana");
setDepthAngle(65);
setPieDepth(45);
restoreAllSlices();
setPieFeelerTextDisplay(2);
setPieTilt(25);
setPieLabelDisplay(1);
setDisplay(getPieLabel(),true);
setLegendAutomatic(false);
setFontStyle(getLegendText(),2);
setFontStyle(getPieSliceLabel(),2);
setTextFormatPreset(getPieSliceLabel(),4);
setFontSizeInPoints(getTitle(),12);
setFontSizeAbsolute(getPieSliceLabel(),true);
setFontSizeInPoints(getPieSliceLabel(),8);
setFontSizeAbsolute(getLegendText(),true);
setFontSizeInPoints(getLegendText(),9);
setTextFormatPattern(getDataText(),"$#,###,###,###.##");
setFontSizeInPoints(getO1Label(),9);
setFontSizeInPoints(getY1Label(),9);
setFontSize(getDataText(),10);
setFontSizeAbsolute(getTitle(),true);
setFontSizeInPoints(getTitle(),12);
setLegendMarkerPosition(0);
setTransparentBorderColor(getChartBackground(),true);
setRect(getPieFrame(), new Rectangle(-15500,-13500,27000,27000));
setRect(getFrame(), new Rectangle(-10400,-10000,25000,30000));
ENDSTYLE
END
-RUN
DEFINE FILE CAR
IMAGE/A200='<img src=http://localhost:8080/approot/baseapp/&GIF_FILE>';
END
TABLE FILE CAR
HEADING
" "
"<IMAGE>"
" "
BY COUNTRY NOPRINT
IF RECORDLIMIT EQ 1
ON COUNTRY SUBFOOT
" "
ON TABLE SET PAGE-NUM OFF
ON TABLE SET HTMLCSS ON
ON TABLE PCHOLD FORMAT EXL2K
ON TABLE SET STYLE *
UNITS=IN,
PAGESIZE='Letter',
LEFTMARGIN=0.400000,
RIGHTMARGIN=0.050000,
TOPMARGIN=0.000000,
BOTTOMMARGIN=0.000000,
ORIENTATION=LANDSCAPE,
SQUEEZE=OFF,
TITLETEXT='Excel Graph',
$
ENDSTYLE
END
-RUN
I don't know if you've tried using an Excel template. This would allow you to "tune" your graph with Excel's settings, as Excel is generating the graph.
Another quick option would be to save a graph in WebFOCUS in a graphical format (e.g. GIF), then embed the object in the spreadsheet.
WebFOCUS 53, 71, 76 - All Platforms
Posts: 15 | Location: Information Builders - Chicago | Registered: May 08, 2003
The way that Tom describes it above is the way it works with the code. If you want to do it a way that I consider a little simpler, then I would create fex to handle your gif (Make sure to do on table save as gifname) and then reference it using the layout composer.
Just an FYI, I've only ever been able to put one image per sheet into excel from webFOCUS. I don't know if tom's way allows anymore.
Eric Woerle WF 7.6.7 Reportting Server ETL 7.6.10 Dev Studio 7.6.7