Focal Point
[CLOSED] WRAP HEADING In PDF???

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/4481093962

February 01, 2008, 11:34 PM
Cyril Joy
[CLOSED] WRAP HEADING In PDF???
Hi,

How can I WRAP heading in PDF. See the following example.

TABLE FILE CAR
PRINT
CAR
DEALER_COST
RETAIL_COST
SALES
HEADING
"THIS IS A LONG TEXT WHICH HAS TO WRAPPED TO TWO OR MORE LINES. CURRENTLY IT IS NOT DISPLAYED PROPERLY DUE TO THE LENGTH OF THE TEXT"
""
ON TABLE SET PAGE-NUM OFF
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT PDF
ON TABLE SET STYLE *
TYPE=HEADING,
SIZE=12,
STYLE=BOLD,
LINE=1,
WRAP=3,
$
ENDSTYLE
END

Thanks for your help!

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


Regards,
Cyril Joy.

WF Production 8008 on Linux.
February 03, 2008, 02:38 PM
Leah
The obvious questions is, why not just two lines of heading? Or is the heading text passed to your report?


Leah
February 03, 2008, 09:05 PM
Cyril Joy
It is a heading text passed as a variable to my report. I tried WRAP/SQUEEZE etc, but none working with PDF. Not sure where I am going wrong.

This message has been edited. Last edited by: Cyril Joy,


Regards,
Cyril Joy.

WF Production 8008 on Linux.
February 04, 2008, 03:38 AM
Tony A
An alternative is to split it yourself using PARAG to position a character to allow you to use the GETTOK function.

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 
February 04, 2008, 08:32 AM
mgrackin
Cyril,

Create a field containing the &variable value and then use the field in your HEADING. Fields will respect the WRAP setting. Straight text in a HEADING will not.

I wrote an article that expalins many of the ways to deal with text and fields in HEADINGs, SUBHEADings, etc. You may find this useful. The information about the field values in a HEADING is further down in the article.

http://www.informationbuilders.com/support/developers/htmlpdf_part2.html


Thanks!

Mickey

FOCUS/WebFOCUS 1990 - 2011
February 04, 2008, 08:38 AM
mgrackin
Cyril,

Here's your code with the necessary changes:

TABLE FILE CAR
PRINT
CAR
DEALER_COST
RETAIL_COST
SALES
COMPUTE HDRTEXT/A150='THIS IS A LONG TEXT WHICH HAS TO WRAPPED TO TWO OR MORE LINES. CURRENTLY IT IS NOT DISPLAYED PROPERLY DUE TO THE LENGTH OF THE TEXT'; NOPRINT
HEADING
"<HDRTEXT"
""
ON TABLE SET PAGE-NUM OFF
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT PDF
ON TABLE SET STYLE *
TYPE=HEADING,
SIZE=12,
STYLE=BOLD,
LINE=1,
WRAP=3,
$
ENDSTYLE
END


Thanks!

Mickey

FOCUS/WebFOCUS 1990 - 2011
February 04, 2008, 10:38 AM
Cyril Joy
Great Idea! Appreciate it. Thanks for your help.


Regards,
Cyril Joy.

WF Production 8008 on Linux.
February 05, 2008, 04:09 PM
ira
Mickey: Nice article. Cyril - that should definitely do it for you.
Ira


aix-533,websphere 5.1.1,apache-2.0,
wf 538(d), 537 (p),
==============
7.6.11 (t) aix 5312
websphere 6.1.19
apache 2.0
May 14, 2008, 05:40 PM
Darin Lee
After playing with this a little, I found it interesting that wrapping a field within a text line works in HEADING, SUBHEAD, SUBFOOT, TABHEADING, AND TABFOOTING, but it does not work correctly (at least in PDF) in FOOTING. It seems to truncate the field after one line at the specified length - as if it doesn't know if there will be enough room for the additional lines of wrapped field value, so it doesn't bother to display them. Can you verify this when you get a minute, Mickey?


Regards,

Darin



In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
May 15, 2008, 08:41 AM
mgrackin
Darin,

You are correct. I am using WF713 and the FOOTING does not show anymore than one line of text. Have you reported this to IBI to see if it is fixed in later releases than what we are using? (me-WF713, you-WF716)

I found a WRAPping issue with fields in HEADINGs in WF713 that IBI says is fixed in WF716. Maybe further fixes are in WF76x.


Thanks!

Mickey

FOCUS/WebFOCUS 1990 - 2011
January 31, 2011, 08:40 AM
MAdams1
FYI.. This issue still isn't fixed in 7.7.1. Which is what led me to this post...


WebFOCUS Server 8.1.05
Windows 2008 Server
WebFOCUS AppStudio 8.1.05
Windows 7 Professional
IE 11 and Chrome Version 43.0.2357.124 m.
Mostly HTML, PDF, Excel, and AHTML
February 01, 2011, 01:02 AM
Ramkumar - Webfous
quote:
Create a field containing the &variable value and then use the field in your HEADING. Fields will respect the WRAP setting. Straight text in a HEADING will not.

I wrote an article that expalins many of the ways to deal with text and fields in HEADINGs, SUBHEADings, etc. You may find this useful. The information about the field values in a HEADING is further down in the article.

http://www.informationbuilders...s/htmlpdf_part2.html



Thatz defenitely an useful article.. Thanks Mickey... Smiler


Thanks,

Ramkumar.
WebFOCUS/Tableau
Webfocus 8 / 7.7.02
Unix, Windows
HTML/PDF/EXCEL/AHTML/XML/HTML5
February 01, 2011, 08:51 AM
mgrackin
You are welcome. I am glad the two articles I wrote are still helping peple even after three years. Smiler


Thanks!

Mickey

FOCUS/WebFOCUS 1990 - 2011
February 01, 2011, 09:00 AM
Ramkumar - Webfous
Smiler True all the way !!!


Thanks,

Ramkumar.
WebFOCUS/Tableau
Webfocus 8 / 7.7.02
Unix, Windows
HTML/PDF/EXCEL/AHTML/XML/HTML5
February 01, 2011, 09:09 AM
MAdams1
I read the articles but I am still having a problem getting an amper variable to center in a heading, it trails off the right side of the page and will not wrap. I have tried to assign the &var to a define field and use that in the heading and it doesn't work. Any other ideas??


WebFOCUS Server 8.1.05
Windows 2008 Server
WebFOCUS AppStudio 8.1.05
Windows 7 Professional
IE 11 and Chrome Version 43.0.2357.124 m.
Mostly HTML, PDF, Excel, and AHTML
September 21, 2011, 03:16 PM
mpbMDE
quote:
http://www.informationbuilders...s/htmlpdf_part2.html


I have read this great article and tried the things that are in it. I still need help along these lines: I have a very long (A8000V) field that I want to wrap in PDF at the subfoot level. In the article the heading works great for wrpping - not so with the subfoot (or footing). It works in HTML format - but not in PDF. Can anyone PLEASE help me?
THANKS!!
Marilyn
version 7.6.11


WebFOCUS 8.1.05 Windows 7, all output
September 21, 2011, 04:49 PM
Francis Mariani
I tried this on v7.7.03 and as you say, wrap with a long footing does not work. It works for tabheading, tabfooting, heading, subhead and subfoot, but not for footing.
I would open a case with IBI. You can use this reproducible code as an example:

-SET &FOOT_TEXT = 'At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, *** soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Temporibus autem quibusdam et aut officiis debitis aut rerum necessitatibus saepe eveniet ut et voluptates repudiandae sint et molestiae non recusandae. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat.';

TABLE FILE CAR
SUM
COMPUTE FOOT_TEXT/A1200 = '&FOOT_TEXT'; NOPRINT
SALES
BY COUNTRY
BY CAR
BY MODEL

ON COUNTRY SUBHEAD
"<FOOT_TEXT"
" "

ON COUNTRY SUBFOOT
" "
"<FOOT_TEXT"

HEADING
"<FOOT_TEXT"
" "

FOOTING
" "
"<FOOT_TEXT"

ON TABLE SUBHEAD
"<FOOT_TEXT"
" "

ON TABLE SUBFOOT
" "
"<FOOT_TEXT"

ON TABLE PCHOLD FORMAT PDF

ON TABLE SET STYLE *
TYPE=REPORT, ORIENTATION=LANDSCAPE, $
TYPE=REPORT, FONT=ARIAL, SIZE=10, $
TYPE=TABHEADING, SIZE=8, WRAP=10, COLOR=PURPLE, $
TYPE=TABFOOTING, SIZE=8, WRAP=10, COLOR=BROWN, $
TYPE=HEADING, SIZE=8, WRAP=10, COLOR=RED, $
TYPE=FOOTING, SIZE=8, WRAP=10, COLOR=BLUE, $
TYPE=SUBHEAD, SIZE=8, WRAP=10, COLOR=GREEN, $
TYPE=SUBFOOT, SIZE=8, WRAP=10, COLOR=ORANGE, $
END
-RUN

If it's acceptable to have the text on only the last page, use ON TABLE SUBFOOT to create a tabfooting.

This message has been edited. Last edited by: Francis Mariani,


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
September 21, 2011, 07:12 PM
Francis Mariani
Same result in v7.6.8 and v7.7.02. I suspect this has been there since the beginning and into the 21st century.


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
September 22, 2011, 09:02 PM
njsden
Don't we love consistency?



Prod/Dev: WF Server 8008/Win 2008 - WF Client 8008/Win 2008 - Dev. Studio: 8008/Windows 7 - DBMS: Oracle 11g Rel 2
Test: Dev. Studio 8008 /Windows 7 (Local) Output:HTML, EXL2K.
September 22, 2011, 10:05 PM
Francis Mariani
Aren't you just the lucky fellow, working on v5.3.4!


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
September 22, 2011, 10:12 PM
njsden
Yep, but not for long ... I think I'm gonna miss it Roll Eyes



Prod/Dev: WF Server 8008/Win 2008 - WF Client 8008/Win 2008 - Dev. Studio: 8008/Windows 7 - DBMS: Oracle 11g Rel 2
Test: Dev. Studio 8008 /Windows 7 (Local) Output:HTML, EXL2K.