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.
I am generating a report and in this report i am sorting on a particular column dynamically.I am displaying this report with in the iframe in the html page.But in the html page printer friendly image is there and on clicking on this the report should come in the pdf format.we are able to achieve this. But the problem is when i am clicking the printer friendly image i have to persist the order of sorting same as in the report in the iframe.we tried using global varibles also. But we are not able to catch the sort order.In the PDF format the report is getting generated with the default sort order only.I would be thankful if anyone can help on this.
Since you are using an HTML page, why don't you try creating a hidden field on the page.
Then, when you perform specific drilldowns, call a javascript function on the main HTML page that sets the hidden field with the values that you want to persist.
You'll probably have to include a -DEFAULT in all your .fexs and relink your .fex in the iFRAME so that the hidden variable is passed to the .fex each time.
Posts: 21 | Location: Texas | Registered: October 24, 2006
When the "printer friendly" image is clicked, you should treat it exactly as you would a self drill report, i.e. pass all the variables necessary to furnish the report.
Therefore, if you have a variable that controls the sort order then pass that as well.
-* File selfdrill.fex
-SET &ECHO = ALL;
-SET &Rand = EDIT(HHMMSS('A8'),'99$99$99');
-DEFAULT &SortBy = 'FOC_NONE'
-DEFAULT &Format = 'HTML'
SET BYDISPLAY = ON
TABLE FILE CAR
SUM RCOST
DCOST
BY &SortBy NOPRINT
BY COUNTRY
BY CAR
BY MODEL
HEADING
" PDF <+0> HTML "
ON TABLE SET ONLINE-FMT &Format
ON TABLE SET STYLE *
TYPE=TITLE, COLUMN=COUNTRY, FOCEXEC=selfdrill.fex(SortBy='COUNTRY' Format='&Format.EVAL' Rand=&Rand), $
TYPE=TITLE, COLUMN=CAR, FOCEXEC=selfdrill.fex(SortBy='CAR' Format='&Format.EVAL' Rand=&Rand), $
TYPE=TITLE, COLUMN=MODEL, FOCEXEC=selfdrill.fex(SortBy='MODEL' Format='&Format.EVAL' Rand=&Rand), $
TYPE=HEADING, ITEM=1, FOCEXEC=selfdrill.fex(SortBy='&SortBy.EVAL' Format='PDF' Rand=&Rand), $
TYPE=HEADING, ITEM=2, FOCEXEC=selfdrill.fex(SortBy='&SortBy.EVAL' Format='HTML' Rand=&Rand), $
ENDSTYLE
END
-RUN
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, 2004
1. Is it by calling the .fex again and redisplaying the entire report again?
OR
2. Are you doing it using some javascript in the web browser.
If 2, then Tony A's solution is the most straight forward and simplest.
If 1, then you aren't retaining anything on the resort, so you'd have to resort to storing info at the HTML level and then passing it when reexecuting the .fex.
Let us know which way your app works.
Posts: 21 | Location: Texas | Registered: October 24, 2006
In the main HTML page, create your button along with some predefined hidden field that will be passed to the "pretty print" fex.
In the iFrame, when you click on your link, you should actually call a javascript function that exists in the main page, and can set values in the hidden field.
Then, when you click the "pretty print" button, it can pass all parameters required, including the hidden field to the "pretty print" fex.
Posts: 21 | Location: Texas | Registered: October 24, 2006
-* File framerpt.fex
-DEFAULT &COUNTRY='FOC_NONE'
TABLE FILE CAR
PRINT
SEATS
BY COUNTRY
BY CAR
BY MODEL
WHERE COUNTRY EQ '&COUNTRY.(FIND COUNTRY IN CAR).Country.';
ON TABLE SET PAGE-NUM OFF
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
UNITS=IN,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
$
TYPE=REPORT,
GRID=OFF,
FONT='ARIAL',
SIZE=9,
COLOR='BLACK',
BACKCOLOR='NONE',
STYLE=NORMAL,
$
TYPE=DATA,
COLUMN=N1,
TARGET='_self',
JAVASCRIPT=window.parent.persist(COUNTRY),
$
ENDSTYLE
END
Now the 2nd report called 'persist.fex'
-* File persist.fex
-DEFAULT &HIDDEN='Not set yet!'
-TYPE The persisted value = &HIDDEN
Posts: 21 | Location: Texas | Registered: October 24, 2006