RTF::Writer table problems (cells wont align correctly)

RTF::Writer table problems (cells wont align correctly)

am 06.04.2007 00:12:55 von Ben Eagle

This is a multi-part message in MIME format.

--===============0471192655==
Content-Class: urn:content-classes:message
Content-Type: multipart/alternative;
boundary="----_=_NextPart_001_01C777CF.8F837A44"

This is a multi-part message in MIME format.

------_=_NextPart_001_01C777CF.8F837A44
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

I having problems with aligning text inside a table,

=20

Only the first row will align to the center Align =3D> 'l c c c'; should
work for the whole table, but it only works for the first row

=20

I have tried multiple ways of doing it and it wont work

=20

Any Ideas??

=20

=20

=20

=20

my @tableProp2 =3D ( widths =3D> [inches(2), inches(2), =
inches(2),
inches(2)],

align =3D> 'c c c c',

);

my $oDecl2 =3D
RTF::Writer::TableRowDecl->new(@tableProp2,);

$oDecl2->add_bgcolors(8); # All cells default
color

$fh->row($oDecl2, \'\fs20 Consolidation
Results', "Current(As Is)", 'With VMware (Projected)', 'Difference');


my @tableProp3 =3D (

=20
widths =3D> [inches(2),inches(2),inches(2),inches(2)],

=20
align =3D> "l c c c" ,

=20

=20

=20
);

my $oDecl3 =3D
RTF::Writer::TableRowDecl->new(@tableProp3,);

$oDecl3->add_bgcolors(7); # All cells default
color

$fh->row($oDecl3, [\'\fs20', 'Servers (N to 1
consolidation ratio)'], [\'\fs20',"$valueHash{\"TCO_1_16\"}"],
[\'\fs20', "$valueHash{\"TCO_2_16\"}"], [\'\fs20',
"$valueHash{\"TCO_3_16\"}"]);

$fh->row($oDecl3, [\'\fs20',"HBAs"],[\'\fs20',
"$valueHash{\"TCO_1_17\"}"], [\'\fs20',"$valueHash{\"TCO_2_17\"}"],
[\'\fs20',"$valueHash{\"TCO_3_17\"}"]);

$fh->row($oDecl3, [\'\fs20',"SAN switches"],
[\'\fs20\qc',"$valueHash{\"TCO_1_18\"}"],
[\'\fs20\qc',"$valueHash{\"TCO_2_18\"}"],
[\'\fs20\qc',"$valueHash{\"TCO_3_18\"}"]);

=20


------_=_NextPart_001_01C777CF.8F837A44
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable




charset=3Dus-ascii">












style=3D'font-size:10.0pt;
font-family:Arial'>I having problems with aligning text inside a =
table,



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>Only the first row will align to the center Align =
=3D> ‘l
c c c’; should work for the whole table, but it only works for the =
first row



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>I have tried multiple ways of doing it and it wont =
work



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>Any Ideas??



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>my @tableProp2 =3D =
(        
widths =3D> [inches(2), inches(2), inches(2), =
inches(2)],



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;           &n=
bsp;   
align =3D> 'c c c c',



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;    
 );



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;  my
$oDecl2 =3D =
RTF::Writer::TableRowDecl->new(@tableProp2,);



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;  $oDecl2->add_bgcolors(8); 
# All cells default color



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;  $fh->row($oDecl2,
\'\fs20 Consolidation Results', "Current(As Is)", 'With VMware
(Projected)', 'Difference');     =
            =



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;  my
@tableProp3 =3D (



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;           &n=
bsp;           &nb=
sp;           &nbs=
p;  =
            &=
nbsp;           widths
=3D> [inches(2),inches(2),inches(2),inches(2)],



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;           &n=
bsp;           &nb=
sp;           &nbs=
p;            =
;            =
  align
=3D> "l c c c" ,



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;           &n=
bsp;           &nb=
sp;           &nbs=
p;            =
;   );



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;  my
$oDecl3 =3D =
RTF::Writer::TableRowDecl->new(@tableProp3,);



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;  $oDecl3->add_bgcolors(7); 
# All cells default color



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;  $fh->row($oDecl3,
[\'\fs20', 'Servers (N to 1 consolidation ratio)'],
[\'\fs20',"$valueHash{\"TCO_1_16\"}"], [\'\fs20',
"$valueHash{\"TCO_2_16\"}"], [\'\fs20',
"$valueHash{\"TCO_3_16\"}"]);



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp;  $fh->row($oDecl3,
[\'\fs20',"HBAs"],[\'\fs20',
"$valueHash{\"TCO_1_17\"}"],
[\'\fs20',"$valueHash{\"TCO_2_17\"}"],
[\'\fs20',"$valueHash{\"TCO_3_17\"}"]);
=



style=3D'font-size:10.0pt;
font-family:Arial'>         =
   =
            =
$fh->row($oDecl3,
[\'\fs20',"SAN switches"],
[\'\fs20\qc',"$valueHash{\"TCO_1_18\"}"], =
[\'\fs20\qc',"$valueHash{\"TCO_2_18\"}"],
[\'\fs20\qc',"$valueHash{\"TCO_3_18\"}"]);
nt>



style=3D'font-size:10.0pt;
font-family:Arial'>         =
            &=
nbsp; 









------_=_NextPart_001_01C777CF.8F837A44--

--===============0471192655==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
ActivePerl mailing list
ActivePerl@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
--===============0471192655==--