Page 1 of 1

Preprocessor statement %PAGE

PostPosted: Wed Jan 09, 2008 6:10 pm
by whale
Developers can use preprocessor statements to make their listing more readable. "%SKIP(n);" allows the developer to add blank lines to the listing for readability. "%PAGE;" begins a new page.


i am unable to understand the above statement which is got from my shop manual(coding standard) .

can any one explain what it says ? where it will be usefull ?

Re: Preprocessor statement %PAGE

PostPosted: Wed Jan 09, 2008 9:01 pm
by arunprasad.k
whale,

I guess SKIPn will leave 'n' blank lines in the listing and page will start the listing in a new page.

Try this following : (I do not (and will not) have access to Mainframes for a couple of weeks :( )

#1 Give SKIP3 in a line of a COBOL code and compile the code. Again I think, it should be the last 5 character of the line. Now look at the listing it should leave 3 blank spaces in the listing. Also try SKIP4, etc.

#2 Give PAGE and try compling the code.

Meanwhile if any of the members have access to Mainframes, lets clarify whale's and my doubts and assumption.

Arun.

Re: Preprocessor statement %PAGE

PostPosted: Wed Jan 09, 2008 9:53 pm
by whale
Give SKIP3 in a line of a COBOL code and compile the code


Thanks for your response .

First of all i asked for pl/1 . i have tried and i got it .
As you said , skip(n) will skip n blank lines in the spool area .
page will start with new page and give all details about the module in the spool area .

Re: Preprocessor statement %PAGE

PostPosted: Fri Jan 11, 2008 1:37 pm
by arunprasad.k
Sorry!! I was looking at the newposts and replying!!

I do NOT see anywhere to which division (COBOL, PL/1, etc) in new post page.

However is that definition same in PL/1?

Re: Preprocessor statement %PAGE

PostPosted: Fri Jan 11, 2008 3:59 pm
by whale
Yes . As i have mentioned in previous reply.

Re: Preprocessor statement %PAGE

PostPosted: Mon Sep 29, 2008 3:56 pm
by gireesh.cgs
Hi,

We can use SKIP/PAGE statements whenever we want to skip some lines or pages and we can see these changes in the output (might be sysprint/output file).
Eg:1

PUT SKIP(3) LIST ('HI HOW ARE YOU?');
-- This statment prints "HI HOW ARE YOU?" after 3 lines of spacing. The default is 1 line spacing.

The same is for PAGE.

Eg: 2
PUT FILE(REPORT) SKIP EDIT(HEADER) (A);
--- This statement puts the header after single line of spacing in the report file.

Regards,
Gireesh.