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     [SOLVED] Ignoring missing HTMTABLE file

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Ignoring missing HTMTABLE file
 Login/Join
 
Platinum Member
posted
Hi,

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 Pang

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


DEV: WF 7.6.10
TEST: WF 7.6.10
PROD: WF 7.6.10
MRE: WF 7.6.4
OS/Platform: Windows
Dev Studio: WF 7.7
Output: HTML, EXCEL, PDF, GRAPH, LOTUS, CSV
 
Posts: 117 | Location: Toronto, Ontario, Canada | Registered: February 29, 2008Report This Post
Silver Member
posted Hide Post
One easy solution is to restrict by programming..

Capture # of records rigth after each HTM table and use IF clause whether to display default message for Report (HTML_1, HTML_2...n)

If above solution doens't solve...Can you post the sample HTML wrapper..

Version:
WF - 7.1.7 /7.6. WFRS - AIX 5.2
HTML, EXCEL, PDF, CSV,WP.
 
Posts: 36 | Location: Boston MA | Registered: October 12, 2006Report This Post
Platinum Member
posted Hide Post
Thanks for the idea, but I want to display the HTML wrapper in all scenario as it gives the heading and footing as well as formatting position.

Here is a sample of the HTML wrapper:

[some heading with gifs and links and introductory descriptions]
...
table border="0" cellspacing="0" cellpadding="3" bgcolor="#f6f5f1"

tr
td
!IBI.FIL.HTML_1;
/td
/tr

tr
td
!IBI.FIL.HTML_2;
/td
/tr

tr
td
!IBI.FIL.HTML_3;
/td
/tr

tr
td
!IBI.FIL.HTML_4;
/td
/tr
tr
td
!IBI.FIL.HTML_5;
/td
/tr
tr
td
!IBI.FIL.HTML_6;
/td
/tr
tr
td
!IBI.FIL.HTML_7;
/td
/tr
/table

...
[some footing descriptions]

Thanks again for your help.

Best Regards,

Jimmy Pang


DEV: WF 7.6.10
TEST: WF 7.6.10
PROD: WF 7.6.10
MRE: WF 7.6.4
OS/Platform: Windows
Dev Studio: WF 7.7
Output: HTML, EXCEL, PDF, GRAPH, LOTUS, CSV
 
Posts: 117 | Location: Toronto, Ontario, Canada | Registered: February 29, 2008Report This Post
Platinum Member
posted Hide Post
I'm not sure how to post HTML code in the forum so I removed all the tags from the code for the HTML wrapper.


DEV: WF 7.6.10
TEST: WF 7.6.10
PROD: WF 7.6.10
MRE: WF 7.6.4
OS/Platform: Windows
Dev Studio: WF 7.7
Output: HTML, EXCEL, PDF, GRAPH, LOTUS, CSV
 
Posts: 117 | Location: Toronto, Ontario, Canada | Registered: February 29, 2008Report This Post
Silver Member
posted Hide Post
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.

Hope one of the above approaches works.

Version: WF 7.1.7 / 7.6
WFRS: AIX 5.3.
HTML, EXCEL, PDF, WP.
 
Posts: 36 | Location: Boston MA | Registered: October 12, 2006Report This Post
Virtuoso
posted Hide Post
Jim,

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 ...
-IF &REC1 EQ 0 GOTO NO1;
<tr> 
<td >
!IBI.FIL.HTML_1;
</td>
</tr>
-NO1
-IF &REC2 EQ 0 GOTO NO2;
<tr> 
<td >
!IBI.FIL.HTML_2;
</td>
</tr>
-NO2
...
-SET &RECALL = &REC1 + &REC2 + ... ;
-IF &RECALL GT 0 GOTO SOMERECS;
<tr> 
<td >
No records found
</td>
</tr>
-SOMERECS

Good luck!


Daniel
In Focus since 1982
wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF

 
Posts: 1980 | Location: Tel Aviv, Israel | Registered: March 23, 2006Report This Post
Platinum Member
posted Hide Post
Thanks, I think I like method 1 better.
The JavaScript should work.
I'll keep you posted on the status.

Have a Happy New Year! =)

Best Regards,

Jimmy Pang


DEV: WF 7.6.10
TEST: WF 7.6.10
PROD: WF 7.6.10
MRE: WF 7.6.4
OS/Platform: Windows
Dev Studio: WF 7.7
Output: HTML, EXCEL, PDF, GRAPH, LOTUS, CSV
 
Posts: 117 | Location: Toronto, Ontario, Canada | Registered: February 29, 2008Report This Post
Platinum Member
posted Hide Post
Hi,

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


Thanks everyone for their input.

Best Regards,

Jimmy Pang


DEV: WF 7.6.10
TEST: WF 7.6.10
PROD: WF 7.6.10
MRE: WF 7.6.4
OS/Platform: Windows
Dev Studio: WF 7.7
Output: HTML, EXCEL, PDF, GRAPH, LOTUS, CSV
 
Posts: 117 | Location: Toronto, Ontario, Canada | Registered: February 29, 2008Report 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     [SOLVED] Ignoring missing HTMTABLE file

Copyright © 1996-2020 Information Builders