SAS PROC TEMPLATE TEXT BREAK LINES

374 Views Asked by At

My aim is to generate an fdf output due to SAS so I can import it into adobe.

Unfortunately, my proc template produced file "template.fdf" is just single row. However, I need a new line of code after every put statement. Is there a way to insert this?

Thank you in advance

PROC TEMPLATE;

DEFINE TAGSET template.FDF / STORE = SASUSER.TEMPLAT; 
DEFINE EVENT DOC_BODY; 
START:

put "%FDF-1.2 "; <=== new breakline in the document
PUT "text"; <=== new breakline in the document
put "<</Root 1 0 R>> ";<=== new breakline in the document
FINISH:        
PUT "%%EOF";
END;END;
RUN;

FILENAME OUT "C:\..\template.FDF"; 
ODS LISTING CLOSE; 
ODS MARKUP BODY = OUT 
TAGSET = template.FDF; 
ODS MARKUP CLOSE; ODS LISTING;
1

There are 1 best solutions below

0
data _null_ On BEST ANSWER

NL option on PUT statement

put "%FDF-1.2 " nl;

From example 3 TEMPLATE Procedure: Creating Markup Language Tagsets