Hello Experts,
Do you know, please how to show a text on italic characters in obj.format_text ?
My code dos'nt work :
obj.format_text( data: "frais forfaitaires : ", overrides: " just=left color=cx95337 font_weight=normal font_size=12pt font_style=italic");
Thank you for your help !
I would expect to see something using Style_attr instead of override
obj.format_text(data: "your text here", style_attr: 'font_style=italic font_size=12pt font_weight=bold color=cxbbb2e0'); |
What ODS style are you using for output? It may be that the font involved did not provide an Italic version.
If you could provide a small complete step to demonstrate it would help. Just enough code that shows the result that we can run.
Thank you for your mesage, Ballardw.
My code is :
%macro fichiers_publipostage_pdf_accord;
%do i=1 %to &nb_obs_nom_prd.;
data _NULL_;
set ACCORD2;
CALL SYMPUTX(COMPRESS('Produit'),Produit);
CALL SYMPUTX(COMPRESS('Code'),Code);
run;
OPTION NODATE NONUMBER;
OPTIONS PAPERSIZE=A4;
options orientation=portrait;
OPTIONS TOPMARGIN=.001 in BOTTOMMARGIN=.001 in LEFTMARGIN=.001 in RIGHTMARGIN=.001 in;
ODS NORESULTS;
ODS PDF FILE = "&Publipostage.\&Code..pdf" dpi=1800;
ODS ESCAPECHAR = "^";
data _NULL_;
declare odsout obj();
obj.layout_absolute(width:
"8.26 in",height:"11.68 in" );
obj.region(width:
"18cm" ,x: "1.5cm", y:"1cm", height:"0.4cm", style_attr: "bordercolor=cx338AF");
obj.line( style_attr: "bordercolor=cx338AFF", size:'0.8mm');
obj.region(width:
" 5 cm",x:"1.5cm", height:"2.2 cm",y:"1.5 cm", style_attr: "bordercolor=cx338AFF bordercolor=cx338AFF");
obj.image(file : "&chemin.\logo_officiel.png" , overrides : " width=100pct ");
obj.region(width:
"8.8 cm",x:"7.5cm", height:"2.7 cm",y:"1.5 cm" ,style_attr: "bordercolor=cx338AFF");
obj.format_text( data: "", overrides: " just=left color=cx95337 font_weight=bold font_size=5pt ");
obj.format_text( data: "Les frais de l'assurance-vie du ", overrides: " just=left color=cx95337 font_weight=bold font_size=16pt ");
obj.format_text( data: "", overrides: " just=left color=cx95337 font_weight=bold font_size=10pt ");
obj.format_text( data: "&Produit.", overrides: " just=left color=cx95337 font_weight=bold font_size=16pt ");
obj.region(width:
"18cm" ,height:"1 cm", x: "1.5cm", y:"3.4 cm", style_attr: "");
obj.line(style_attr: "bordercolor=cx338AFF", size:'0.8mm');
obj.region(width:
"18cm" ,height:"20 cm", x: "1.5cm", y:"4.2 cm", style_attr: "");
obj.format_text( data: "Montant minimal de versement initial : &Montant_min_de_vers_init. ", overrides: "just=left color=cx95337 font_weight=normal font_size=12pt");
obj.format_text( data: "", overrides: " just=left color=cx95337 font_weight=normal font_size=12pt");
obj.format_text( data: "", overrides: " just=left color=cx95337 font_weight=normal font_size=12pt");
obj.format_text( data: "Dont taux de rétrocession de commission", overrides: "just=left color=cx95337 font_weight=normal style=italic font_size=12pt");
obj.format_text( data: "Dont taux de rétrocession de commission", overrides: "just=left color=cx95337 font_weight=normal style=italic font_size=12pt");
run;
%end;
%mend;
%fichiers_publipostage_pdf_accord;
Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.
Register today!Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Select SAS Training centers are offering in-person courses. View upcoming courses for: