I am required to put a footer in my report which is- "This Report is Confidential Page x of y UserID: xyz"
It is in a single line, with 3 different parts- 1)This Report is Confidential 2)Page x of y 3)UserID: xyz
I want these 3 parts to appear in different cells of excel sheet, I have used HEADALIGN=BODY for it but when I use TABPAGENO and TABLASTPAGE they all appear in different cells. Code that I have used is-
SET EMPTYREPORT=ON -SET &USR = GETUSER(USERID); TABLE FILE TRAINING PRINT PIN COURSESTART COURSECODE EXPENSES GRADE FOOTING "This report is confidential <+0> PAGE <TABPAGENO of <TABLASTPAGE <+0> USER ID: &USR " ON TABLE ROW-TOTAL AS 'TOTAL' ON TABLE NOTOTAL ON TABLE PCHOLD FORMAT EXL2K ON TABLE SET STYLE * UNITS=IN, PAGESIZE='SCREEN', LEFTMARGIN=0.000000, RIGHTMARGIN=0.000000, TOPMARGIN=0.000000, BOTTOMMARGIN=0.000000, SQUEEZE=ON, ORIENTATION=PORTRAIT, $ TYPE=FOOTING, HEADALIGN=BODY, $ ENDSTYLE END
Please guide me.This message has been edited. Last edited by: Piscian,
Thanks and Regards, Piscian
WebFocus 714 Windows Server 2003 Enterprise Edition HTML,Excel,PDF
January 28, 2008, 09:24 AM
Tony A
Piscian,
Your problem is that when using spot markers (the < +0>), WebFOCUS also treats a fieldname (e.g. < TABPAGENO) as a spot marker of sorts, so in your footer text you actually have seven component parts.
You could use HEADALIGN=INTERNAL which will place the whole footing text into a merged cell equal to the width of the report (like COLSPAN=6) which is what most folks do (as I have seen anyway).
I am sure that I have seen a method of column alignment somewhere in the forum but you would have to search for it. I can't remember where it was . Try searching on HEADALIGN
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
January 29, 2008, 07:56 AM
Piscian
Thanks Tony.
But when I use HEADALIGN=INTERNAL I get complete message in continuation, like-
This Report is confidential Page x of y UserID:xyz
I want some space between them. Space is not displayed even if I put spaces manually, I have also tried using <3 for inserting spaces but its not working, may be version problem.
Thanks and Regards, Piscian
WebFocus 714 Windows Server 2003 Enterprise Edition HTML,Excel,PDF
January 29, 2008, 08:12 AM
Tony A
Exactly as I said it would -
quote:
which will place the whole footing text into a merged cell equal to the width of the report
Not a version problem but it is how WebFOCUS is and has been
You could always try to ask for a NFR.
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
January 29, 2008, 08:22 AM
Piscian
Is there any way we can get spaces inserted between text?
Thanks and Regards, Piscian
WebFocus 714 Windows Server 2003 Enterprise Edition HTML,Excel,PDF
January 29, 2008, 08:57 AM
Tony A
Piscian,
Do you have to have it on one line? If not then you can play on the ability to have separate HEADALIGN properties for FOOTING and TABFOOTING -
SET EMPTYREPORT=ON
-SET &USR = GETUSER(USERID);
TABLE FILE TRAINING
PRINT
PIN
COURSESTART
COURSECODE
EXPENSES
GRADE
FOOTING
"This report is confidential <+0> USER ID: &USR "
ON TABLE SUBFOOT
"Page <TABPAGENO of <TABLASTPAGE"
ON TABLE ROW-TOTAL AS 'TOTAL'
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT EXL2K
ON TABLE SET STYLE *
UNITS=IN,
PAGESIZE='SCREEN',
LEFTMARGIN=0.000000,
RIGHTMARGIN=0.000000,
TOPMARGIN=0.000000,
BOTTOMMARGIN=0.000000,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
$
TYPE=FOOTING, HEADALIGN=BODY, $
TYPE=FOOTING, LINE=1, ITEM=1, COLSPAN=3, JUSTIFY=LEFT, $
TYPE=FOOTING, LINE=1, ITEM=2, COLSPAN=3, JUSTIFY=RIGHT, $
TYPE=TABFOOTING, LINE=1, COLSPAN=6, JUSTIFY=CENTER, HEADALIGN=INTERNAL, $
ENDSTYLE
END
Note that this will only suffice for a single page report as the ON TABLE SUBFOOT will produce one per report. However, if you use this on a page break field then you could be OK.
Never give in, there's always a way (normally )
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
January 30, 2008, 11:34 AM
PBrightwell
THIS is ugly, but close
[code] SET EMPTYREPORT=ON -SET &USR = GETUSER(USERID); DEFINE FILE TRAINING SP/A1=' '; PG/A15=' Page '; OF/A4=' of '; END TABLE FILE TRAINING PRINT TABPAGENO NOPRINT TABLASTPAGE NOPRINT PIN COURSESTART COURSECODE EXPENSES GRADE BY SP NOPRINT -* ON SP COMPUTE FT1/A30='PAGE '|EDIT(TABPAGENO)|' of ' | EDIT(TABLASTPAGE); ON SP SUBFOOT "This report is confidential USER ID: &USR " ON TABLE ROW-TOTAL AS 'TOTAL' ON TABLE NOTOTAL ON TABLE PCHOLD FORMAT EXL2K ON TABLE SET STYLE * UNITS=IN, PAGESIZE='SCREEN', LEFTMARGIN=0.000000, RIGHTMARGIN=0.000000, TOPMARGIN=0.000000, BOTTOMMARGIN=0.000000, SQUEEZE=OFF, ORIENTATION=PORTRAIT, $ TYPE=SUBFOOT, HEADALIGN=BODY, $ TYPE=SUBFOOT, ITEM=1, HEADALIGN=BODY, COLSPAN=2, $ TYPE=SUBFOOT, ITEM=2, HEADALIGN=BODY, JUSTIFY=RIGHT, $
TYPE=SUBFOOT, ITEM=6, HEADALIGN=BODY, JUSTIFY=RIGHT, $ ENDSTYLE END
[\code] the only other suggestion I can make is to put '*' or '-' or some other printable character to space out the line.This message has been edited. Last edited by: PBrightwell,
Pat WF 7.6.8, AIX, AS400, NT AS400 FOCUS, AIX FOCUS, Oracle, DB2, JDE, Lotus Notes