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 currently have a fex that holds to HTM table format like the following.
TABLE FILE [someTable] ... ON TABLE HOLD AS HTML_1 FORMAT HTMTABLE
TABLE FILE [otherTable] ... ON TABLE HOLD AS HTML_2 FORMAT HTMTABLE
I have other fex programs that does the same hold file name, but they can have more than 2 hold format HTMTABLE files (ie. HTML_3, HTML_4, ... etc).
The problem I have is that I have one HTML wrapper that displays them all one after another(HTML_1,...,HTML_n) so that they are all in the same format structure (header and footer) without having to create a new wrapper for each combination. When one of the hold files are missing it gives me the error
(FOC36225) UNABLE TO OPEN FILE HTML_4 SPECIFIED BY WEBFOCUS TABLE
I was wondering if there is any options that I can set to ignore missing files so that the error does not display?
The reason that I want to have only one HTML wrapper for all fex is so that maintainence would be easier for any changes/updates to the appearance.
Or is there another way that can do the same thing?
Any help would be great. Thanks.
Best Regards,
Jimmy PangThis message has been edited. Last edited by: fatboyjim,
Jim - There are 2 approches to this. 1. Using JavaScript for displaying dynamic content. - Clean approach. 2. If HTML_2 is not generated you can display a standard message or just a line. - work around.
Method_1: Using Javascript. 1. you have to pass Amper variable to determin how many hold files and their hold file Names to HTML Wrapper section. 2.Write Javascript function which will dynamically create by using loops and some string functions.
<tr> <td> !IBI.FIL.HTML_1 </td></tr>
Method_2: if HTML_1 is not created due to some good reason. just created another HTMTABLE with or just another standard message. In Method_2: you have to created HTML tags in Define statement.
When you run your TABLE request add some DM to find out how many records were selected:
TABLE FILE [someTable]
...
ON TABLE HOLD AS HTML_1 FORMAT HTMTABLE
END
-RUN
-SET &REC1=&RECORDS;
TABLE FILE [someTable]
...
ON TABLE HOLD AS HTML_2 FORMAT HTMTABLE
END
-RUN
-SET &REC2=&RECORDS;
....
Then when you arrive at your "wrapper" you can test the &REC1, &REC2 ...
I've finally been able to try the methods above out.
Javascript Method -> Due to lack of javascript knowledge, and wasn't able spend much time to investigate on it, so wasn't able to have a working module/example of it. But it looks easy enough that it'll work (Thanks WF_Novice)
DM Method -> I was able to use this (Thanks Danny-SRL)
I used a modified for the DM Method because my program displays results sequencially and dependent on the prior section (ie. if I am displaying HOLD file HTML_4, I know that I am also displaying HTML_1, HTML_2, and HTML_3).
My solution was to have a tracking variable on the number of HOLD files and at the end loop to display the number of hold files in the wrapper. &NUMHTML is my counter to keep track of the number of HOLD HTML files
-HTMLFORM BEGIN
...some HTML header for entire report
-HTMLFORM END
-REPEAT :LPHMTL FOR &I FROM 1 TO &NUMHTML STEP 1
-HTMLFORM BEGIN
!IBI.FIL.HTML_&I;
-HTMLFORM END
-:LPHMTL
-HTMLFORM BEGIN
...some HTML footer for entire report
-HTMLFORM END