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     [CLOSED] Embedding HTML data in PDF format

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Embedding HTML data in PDF format
 Login/Join
 
Member
posted
Hi,

Our data consists of some HTML tags to apply some format for record, this HTML tags renders in HTML and Excel output formats. Is there any way to render these HTML tags in PDF output format?

The data consists of many html tags like
 <h1> , <br>, <table>, etc..  


Please suggest me is there any way I can use html tags in my PDF format.

I am using WebFOCUS 7.7.03 and database in Oracle.

Thanks,
Kumaravel.M

This message has been edited. Last edited by: <Kathryn Henning>,
 
Posts: 13 | Registered: September 29, 2008Report This Post
Guru
posted Hide Post
Do a search for MARKUP=ON. From what I have found it works best in the DATA report component.
Also not every html tag is supported. If this required you have to find a third party tool that will convert html to pdf.
  
TABLE FILE CAR
PRINT
   COMPUTE CNTRY/A50 = '[b]<u>' || COUNTRY || '</u>[/b]';  AS 'Country'

BY COUNTRY NOPRINT
ON TABLE SET PAGE-NUM NOLEAD
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT PDF
ON TABLE SET HTMLCSS ON
ON TABLE SET HTMLENCODE OFF
ON TABLE SET STYLE *
UNITS=IN,PAGESIZE='Letter',LEFTMARGIN=0.250000,RIGHTMARGIN=0.250000,TOPMARGIN=0.250000,BOTTOMMARGIN=0.250000,SQUEEZE=ON,ORIENTATION=LANDSCAPE,$
TYPE=REPORT,FONT='ARIAL',SIZE=8,COLOR='BLACK',STYLE=NORMAL,BORDER=OFF,LEFTGAP=0.05,RIGHTGAP=0.05,$
TYPE=REPORT,COLUMN=N2,WRAP=1.00,$
TYPE=DATA,COLUMN=N2,MARKUP=ON,$
ENDSTYLE
END
-RUN


WebFOCUS 8.1.05M Unix Self-Service/MRE/Report Caster - Outputs Excel, PDF, HTML, Flat Files
 
Posts: 320 | Location: Memphis, TN | Registered: February 12, 2008Report This Post
Expert
posted Hide Post
You could try using something reserved for Compound reports, "MARKUP", but I haven't had much luck with it:

TYPE=REPORT, MARKUP=ON, ...


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Member
posted Hide Post
Hi,

Thanks Mighty Max and Francis for your valuable replies. The MARKUP=ON is converting only some of basic styling HTML tags like
 <b>,<i>,<u>, etc.. 
but its not supporting all the HTML tags for eg, its not supporting
 <table>, <h1>, <br>, etc.. 
Please see the below sample code I tried.
DEFINE FILE CAR
DCAR/A50 = '<h1>'||CAR||'</h1><br><u>'||COUNTRY||'</u>';
-*DCAR/A100 = '<TABLE BORDER=1><TR><TD>'||CAR||'</TD></TR><TR><TD>'||COUNTRY||'</TD></TR></TABLE>';
END

TABLE FILE CAR
BY CAR NOPRINT
BY DCAR
ON TABLE SET PAGE-NUM NOLEAD
ON TABLE SET HTMLCSS ON
ON TABLE PCHOLD FORMAT PDF
ON TABLE SET STYLE *
TYPE=REPORT, GRID=OFF, $
TYPE=DATA,COLUMN=N2,MARKUP=ON,$
TYPE=REPORT, COLUMN=N2, WRAP=3.00, $
ENDSTYLE
END
-EXIT  


Please give your suggestion on this.

Thanks,
Kumaravel.M
 
Posts: 13 | Registered: September 29, 2008Report This Post
Expert
posted Hide Post
Yes, it definitely does not deal with all HTML tags.

I've used SQL passthrou to strip HTML tags, but you will not get the styling that some of the tags perform. The syntax is a little confusing, but I'm removing HTML space characters and HTML tags that begin with < and end with >. This, of course does not deal with all HTML...

SQL SQLORA
select
line_num,
-*regexp_replace ( regexp_replace ( regexp_replace ( comment_text, '<p>', ' ', 1, 0, 'i' ), '<br>', ' ', 1, 0, 'i' ), '<[^>]*>', ' ' ) as comment_text
regexp_replace ( regexp_replace ( comment_text, '&|nbsp;', ' ', 1, 0, 'i' ), '<[^>]*>', ' ' ) as comment_text
-*regexp_replace ( comment_text, '<[^>]*>', ' ' ) as comment_text
from entrpt.rpt_comment
where report_cde = 'BM_PERF_DASHBRD'
and section = 'Notes'
and crnt_ind = 1
;
TABLE ON TABLE HOLD AS HCOMMENT1
END
-RUN


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report 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     [CLOSED] Embedding HTML data in PDF format

Copyright © 1996-2020 Information Builders