Hello Experts,
I don't understand why I have the error in obj.format_text :
I don't think that I need to add a parenthesis to my code.
Maybe this error is linked with the first error (error of file)?
All is seems to be correct in my code :
proc sql noprint;
select count(distinct Code) into :nb_obs_nom_prd from Accord;
quit;
%macro fichiers_publipostage_pdf_accord;
%do i=1 %to &nb_obs_nom_prd.;
data _NULL_;
set ACCORD;
CALL SYMPUTX(COMPRESS('Produit'),Produit);
CALL SYMPUTX(COMPRESS('Code'),Code);
CALL SYMPUTX(COMPRESS('Montant_min_de_vers_init'),Montant_min_de_vers_init);
CALL SYMPUTX(COMPRESS('FRAIS_GESTION_OL_UC2'),FRAIS_GESTION_OL_UC);
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: "Frais d'adhésion à l'association ayant souscrit le contrat ", overrides: "just=left color=cx95337 font_weight=normal font_size=14pt");
obj.format_text( data: "", overrides: " just=left color=cx95337 font_weight=normal font_size=12pt");
obj.format_text( data: "Frais annuels ", overrides: " just=left color=cx95337 font_weight=bold font_size=12pt");
obj.format_text( data: "", overrides: " just=left color=cx95337 font_weight=normal font_size=12pt");
run;
%end;
%mend;
%fichiers_publipostage_pdf_accord;
Thank you for your help !
... View more