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.



Read-Only Read-Only Topic
Go
Search
Notify
Tools
OUTPUT OPTION
 Login/Join
 
Silver Member
posted
HI,
i have a report and its output is html. i need to add a button to this output and when the user clicks the button the same report must appear in pdf.is there a way to achieve this .
thanks
 
Posts: 37 | Registered: December 28, 2005Report This Post
Guru
posted Hide Post
Yes,
You will need to pass a variable from the GUI.
In the following example the value of &OUTPUT will need to be HTML or PDF.

TABLE FILE CAR
SUM
     RETAIL_COST
BY
     COUNTRY
ON TABLE PCHOLD FORMAT &OUPUT
END


Also do a search there should be other example of this on here.
 
Posts: 406 | Location: Canada | Registered: May 31, 2004Report This Post
Silver Member
posted Hide Post
Hi reFocusing,
thanks for your reply but thats not the way i want.
user selects options and based on those options report is generated and the output of this report is html.now after viewing the report output to enable the user to take the print out of the output i need to create a button/link in the report which on clecking should display the same data in pdf format(printer version).
thanks
 
Posts: 37 | Registered: December 28, 2005Report This Post
Guru
posted Hide Post
To elaborate on reFOCUSing's suggestion, I have seen HTML reports that have included buttons for EXCEL and/or PDF output formats somewhere on the report such that the report (fex) is re-executed with the chosen format.


jimster06
DevStu WF 7.6.11
W7
HTML, PDF, EXL2K
 
Posts: 252 | Location: USA | Registered: April 15, 2003Report This Post
Platinum Member
posted Hide Post
If you're not too concerned with using button to press, I have used icons for both Excel and PDF that I add to the footing of a report. They have drilldowns associated with them in the stylesheet. When the user clicks on the icon, the report is produced in either Excel or PDF accordingly.

However, I have experiemented with buttons and there's no problem adding them. I just haven't had the opportunity to try to get them to execute a report.

Ken


Prod - WF 7.6.4 Unix/Solaris - Self-Service, BI Dashboard, MRE
Dev - WF 7.6.4 Unix/Solaris - Self-Service, BI Dashboard, MRE
Databases: Oracle 10g, SQL Server 2000, DB2.
 
Posts: 177 | Location: Calgary, Alberta, Canada | Registered: April 25, 2005Report This Post
Silver Member
posted Hide Post
Hi k.lane
can you please send me the sample code of what you have done in your report so that i can try to use it and see if it works.
Thanks
kiran
 
Posts: 37 | Registered: December 28, 2005Report This Post
Platinum Member
posted Hide Post
This works:

-DEFAULT &OUTPUT = 'HTML' ;

TABLE FILE CAR
SUM SALES
COMPUTE PDFIMAGE /A160 = '~img border=0 src=' || '''' ||
'http://SERVERNAME/approot/APPNAME/images/s_pdf.gif' ||
'''' || '>~/img>'; NOPRINT
BY CAR
-IF &OUTPUT EQ 'PDF' THEN GOTO NOFOOT ;
FOOTING
"-NOFOOT
ON TABLE SET STYLE *
TYPE=FOOTING, FOCEXEC=a1(OUTPUT='PDF'),$
ENDSTYLE
ON TABLE PCHOLD FORMAT &OUTPUT
END


where,

~ - The left caret.

a1 - the name of this focexec. It will drill into itself.

SERVERNAME - server
APPNAME - DS appname

Of course, it's dependent upon how things are organized in your installation.

But, this should give you the jist of what I was referring to.

I'd really be interested in the button method, but I just don't have the time to look into it.

Ken


Prod - WF 7.6.4 Unix/Solaris - Self-Service, BI Dashboard, MRE
Dev - WF 7.6.4 Unix/Solaris - Self-Service, BI Dashboard, MRE
Databases: Oracle 10g, SQL Server 2000, DB2.
 
Posts: 177 | Location: Calgary, Alberta, Canada | Registered: April 25, 2005Report This Post
Silver Member
posted Hide Post
thanks ken, i am now able to create the link and this should be enough for now and i am trying the button option and if it works i will post that too.once again thanks for your suggestion
 
Posts: 37 | Registered: December 28, 2005Report This Post
Expert
posted Hide Post
Kiran,

The method I use involves calling JavaScript but could easily be set up to point at an HRef instead.

BUTTONS/A320 = ' || ' title="Report in Excel Format" onClick=openReport("application","report","EXL2K")>'
|| ' || ' title="Report in PDF Format" onClick=openReport("application","report","PDF")>';


The JavaScript function just creates a new window without certain toolbars etc. and would need to be included into your fex using SET JSURL. It could be extended to expect any number of parameters.

function openReport(app,fexname,format) {
URL = "/cgi-bin/ibi_cgi/ibiweb.exe?IBIAPP_app="+app+"&IBIF_ex="+fexname+"&Format="+format;
OpenWin = this.open(URL, "_blank", "toolbar=no,menubar=no,location=no,scrollbars=yes,status=no,resizable=yes");

}

T

This message has been edited. Last edited by: <Mabel>,



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
  Powered by Social Strata  

Read-Only Read-Only Topic


Copyright © 1996-2020 Information Builders