Focal Point
Closed not solved - How can I type a line title with spacing whithin Report painter

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

January 28, 2010, 02:29 PM
Marikaki
Closed not solved - How can I type a line title with spacing whithin Report painter
Hi,

So little things bug me like this situation: Please see the printed line:

MOIS COURANT 2010 MOIS COURANT 2009 ANNÉES CUMULÉES FIN January

But I would like:

MOIS COURANT 2010 MOIS COURANT 2009 ANNÉES CUMULÉES FIN January

In the same time I didn't find out yet how to translate the month in french.

Here's the code:

DEFINE FILE V_SLSWKBGT
-* Date format
DPERIODYR/P4YY=PERIODYR;
DPERIODLY/P4YY=PERIODYR - 1;
-* Full month name
FPERIOD/Mtr=APERIOD;
END
...
HEADING
"&TITLE_1"
" "
"&TITLE_2"
"&TITLE_3<+0> " "
"MOIS COURANT <+0> MOIS COURANT <+0> ANNÉES CUMULÉES FIN ...
ON TABLE PCHOLD FORMAT EXL2K
ON TABLE SET STYLE *
UNITS=IN,
PAGESIZE='Legal',
LEFTMARGIN=0.000000,
RIGHTMARGIN=0.000000,
TOPMARGIN=0.000000,
BOTTOMMARGIN=0.000000,
SQUEEZE=ON,
ORIENTATION=LANDSCAPE,
PAGECOLOR='WHITE',
$
TYPE=REPORT,
FONT='ARIAL',
SIZE=10,
GRID=ON,
$
TYPE=TITLE,
FONT='ARIAL',
SIZE=8,
COLOR='WHITE',
BACKCOLOR=RGB(27 80 182),
STYLE=BOLD,
JUSTIFY=RIGHT,
$
TYPE=HEADING,
BORDER-TOP=MEDIUM,
BORDER-BOTTOM=MEDIUM,
BORDER-LEFT=OFF,
BORDER-RIGHT=OFF,
BORDER-BOTTOM-STYLE=OUTSET,
BORDER-LEFT-STYLE=RIDGE,
BORDER-RIGHT-STYLE=RIDGE,
BORDER-TOP-COLOR='WHITE',
BORDER-BOTTOM-COLOR='WHITE',
BORDER-LEFT-COLOR='WHITE',
BORDER-RIGHT-COLOR='WHITE',
FONT='ARIAL',
SIZE=8,
STYLE=BOLD,
...
Thanks to all participants!

This message has been edited. Last edited by: Marikaki,
January 28, 2010, 02:37 PM
Marikaki
Sorry but the spacing didn't appear in my title. Here's again:

MOIS COURANT 2010 MOIS COURANT 2009 ANNÉES CUMULÉES FIN January

Thanks.


Marikaki

WF 7.7.03m, MRE, BI Dashboard, DevStudio, Report Caster, Windows 7, I.E. 8/9, Apache Tomcat 6.0, Derby Output formats: Excel2K, PDF, HTML, AHTML

January 28, 2010, 02:39 PM
Marikaki
Really I can't show you. So I explain:

I want spacing after MOIS COURANT 2010 and after MOIS COURANT 2009.

Thanks.


Marikaki

WF 7.7.03m, MRE, BI Dashboard, DevStudio, Report Caster, Windows 7, I.E. 8/9, Apache Tomcat 6.0, Derby Output formats: Excel2K, PDF, HTML, AHTML

January 28, 2010, 02:47 PM
njsden
quote:
I didn't find out yet how to translate the month in french.


Please have a look at the DATETRAN function.

- Neftali.



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.
January 28, 2010, 02:50 PM
njsden
Can you please post again the heading as you want it along with some mocked up data to better understand the layout you expect?

Make sure you enclose it between
[code]
and
[/code]
when posting it!

Thanks,
- Neftali.



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.
January 28, 2010, 03:15 PM
rfbowley
Well, you won't get HTML, to show mulitple spaces so, here are some options for the different formats:

For HTML you could create an ampersand variable as follows:

-SET NBSP = '&' || 'nbsp';


You need to create the variable because WebFOCUS will try to evaluate the non breakable space character from HTML as a variable, and throw a "Value missing" error other wise.

Now just add as many spaces to your line as you need like this:

MOIS COURANT 2010 &NBSP &NBSP MOIS COURANT 2009 &NBSP &NBSP ANNÉES CUMULÉES FIN January


Another option that works with both HTML and EXCEL is to use HEADALIGN in your styling:

TYPE=HEADING,
    HEADALIGN=BODY,
$


Now control the spacing with the column width, the drawback being that you will affect the width of the data column with this. The existing <0> elements you have in this lime will drop your pieces of the HEADING into separate cells in EXCEL.

And our ever favorite output format, PDF, just change the <0> to where xx equals the exact character position, counted from left to right, where you want the next element to appear.

And yes, DATETRAN is the function you want to show January in French unless you change the entire configuration of your sever so that French is the default rather than English.

Hope this helps,


Robert F. Bowley Jr.
Owner
TaRa Solutions, LLC

In WebFOCUS since 2001
January 28, 2010, 03:29 PM
Marikaki
the heading should like:

 
MOIS COURANT 2010________spacing_________MOIS COURANT 2009 ________spacing_________ANNÉES CUMULÉES FIN January



Marikaki

WF 7.7.03m, MRE, BI Dashboard, DevStudio, Report Caster, Windows 7, I.E. 8/9, Apache Tomcat 6.0, Derby Output formats: Excel2K, PDF, HTML, AHTML

January 28, 2010, 04:58 PM
njsden
quote:
Another option that works with both HTML and EXCEL is to use HEADALIGN in your styling:
TYPE=HEADING,
    HEADALIGN=BODY,

$


Robert's solution is the way to go since your output format seems to be EXL2K.

You will need to play with the spotmarkers to put the contents in your headings aligning with your report columns.

Check the documentation on some style sheet keywords you will most likely end up playing with such as:

TYPE=HEADING, LINE=n, OBJECT=x, ITEM=n,   COLSPAN=n, $


As Robert put it, PDF is an entirely different animal and neither HEADALIGN nor COLSPAN will help you there.

- Neftali.



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.
January 28, 2010, 05:46 PM
Marikaki
Hi Robert, Thank you for taking time to explain me usefull tips to control the spacing.

I forgot to mention that the output is EXL2K im my report, but I tried to see the amper variable result in HTML. Looks like it didn't work. Is there a numeric value or a set of blanks in any of NBSP or   variables that I have to set? If not, what will be the spacing-length?

HTML RESULT:

   
MOIS COURANT 2010   MOIS COURANT 2009 ANNÉES CUMULÉES FIN January 


EXLK USING HEADALIGN=BODY:

It's getting better but ...
Why do I get a skipped cell when I have in my title 2 consecutive variables like this:
Again, thank you


Marikaki

WF 7.7.03m, MRE, BI Dashboard, DevStudio, Report Caster, Windows 7, I.E. 8/9, Apache Tomcat 6.0, Derby Output formats: Excel2K, PDF, HTML, AHTML

January 28, 2010, 05:50 PM
Marikaki
Correction:

 Is there a numeric value or a set of blanks in any of NBSP or    variables that I have to set? 


 Why do I get a skipped cell when I have in my title 2 consecutive variables like this: 
<var <var2? 



Marikaki

WF 7.7.03m, MRE, BI Dashboard, DevStudio, Report Caster, Windows 7, I.E. 8/9, Apache Tomcat 6.0, Derby Output formats: Excel2K, PDF, HTML, AHTML

January 28, 2010, 06:46 PM
Dan Satchell
The space between the variables is considered text and is assigned its own cell. Try removing the space if you want the variables placed in adjacent cells.
<var1<var2



WebFOCUS 7.7.05
January 29, 2010, 01:58 AM
Tony A
quote:
-SET NBSP = '&' || 'nbsp';

The correct use of string substitution in HTML is to add the trailing semi-colon-

&nbsp;  for non blanking space  
&amp;   for ampersand         &
&lt;      for left carat              <
&gt;      for right carat            >
&copy;  for copyright symbol    ©
etc. etc. etc.

T

This message has been edited. Last edited by: Tony A,



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, 2010, 03:33 PM
Marikaki
Thanks Dan, exactly what I need. It works.


Marikaki

WF 7.7.03m, MRE, BI Dashboard, DevStudio, Report Caster, Windows 7, I.E. 8/9, Apache Tomcat 6.0, Derby Output formats: Excel2K, PDF, HTML, AHTML

January 29, 2010, 03:38 PM
Marikaki
Thank you for your input. Even if my report is not yet completed, this help me so far to get closer to the end result.

quote:
Originally posted by njsden:
quote:
Another option that works with both HTML and EXCEL is to use HEADALIGN in your styling:
TYPE=HEADING,
    HEADALIGN=BODY,

$


Robert's solution is the way to go since your output format seems to be EXL2K.

You will need to play with the spotmarkers to put the contents in your headings aligning with your report columns.

Check the documentation on some style sheet keywords you will most likely end up playing with such as:

TYPE=HEADING, LINE=n, OBJECT=x, ITEM=n,   COLSPAN=n, $


As Robert put it, PDF is an entirely different animal and neither HEADALIGN nor COLSPAN will help you there.

- Neftali.



Marikaki

WF 7.7.03m, MRE, BI Dashboard, DevStudio, Report Caster, Windows 7, I.E. 8/9, Apache Tomcat 6.0, Derby Output formats: Excel2K, PDF, HTML, AHTML

February 03, 2010, 09:18 AM
GinnyJakes
Methinks you may be making this too hard:
quote:
By default, HTML browsers and Excel remove leading and trailing blanks from text and compress multiple internal blanks to a single blank.

If you want to preserve leading and internal blanks in HTML and EXL2K report output, you can issue the SET SHOWBLANKS=ON command.

Even if you issue this command, trailing blanks will not be preserved except in heading, subheading, footing, and subfooting lines that use the default heading or footing alignment.


--------------------------------------------------------------------------------
Top of page
--------------------------------------------------------------------------------


Syntax: How to Preserve Leading and Internal Blanks in HTML and EXL2K Reports
In a FOCEXEC or in a profile, use the following syntax:

SET SHOWBLANKS = {OFF|ON}
In a request, use the following syntax

ON TABLE SET SHOWBLANKS {OFF|ON}
where:

OFF
Removes leading blanks and compresses internal blanks in HTML and EXL2K report output.

ON
Preserves leading blanks internal blanks in HTML and EXL2K report output. Also preserves trailing blanks in heading, subheading, footing, and subfooting lines that use the default heading or footing alignment.

The full text can be found here:
http://documentation.informati...g/source/topic89.htm


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
February 03, 2010, 04:46 PM
Marikaki
Hi everyone,

I'm not yet done with this issue because I did have to correct wrong data on my report prior to that and I am almost done. I supposed that tomorrow I will be able to continue with the french title. Thank you.

I apologize.


Marikaki

WF 7.7.03m, MRE, BI Dashboard, DevStudio, Report Caster, Windows 7, I.E. 8/9, Apache Tomcat 6.0, Derby Output formats: Excel2K, PDF, HTML, AHTML