Preprocessor statement %PAGE



IBM's cross-platform compiler PL/I for MVS, VM & VSE, OS/390 and Enterprise PL/I for z/OS

Preprocessor statement %PAGE

Postby whale » Wed Jan 09, 2008 6:10 pm

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 ?
Regards ,
whale
_______________________________________
Self-confidence, hard work can ensure success
whale
 
Posts: 8
Joined: Mon Dec 17, 2007 8:19 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Preprocessor statement %PAGE

Postby arunprasad.k » Wed Jan 09, 2008 9:01 pm

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.
arunprasad.k
 
Posts: 110
Joined: Thu Dec 27, 2007 5:18 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Preprocessor statement %PAGE

Postby whale » Wed Jan 09, 2008 9:53 pm

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 .
Regards ,
whale
_______________________________________
Self-confidence, hard work can ensure success
whale
 
Posts: 8
Joined: Mon Dec 17, 2007 8:19 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Preprocessor statement %PAGE

Postby arunprasad.k » Fri Jan 11, 2008 1:37 pm

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?
arunprasad.k
 
Posts: 110
Joined: Thu Dec 27, 2007 5:18 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Preprocessor statement %PAGE

Postby whale » Fri Jan 11, 2008 3:59 pm

Yes . As i have mentioned in previous reply.
Regards ,
whale
_______________________________________
Self-confidence, hard work can ensure success
whale
 
Posts: 8
Joined: Mon Dec 17, 2007 8:19 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Preprocessor statement %PAGE

Postby gireesh.cgs » Mon Sep 29, 2008 3:56 pm

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.
gireesh.cgs
 
Posts: 2
Joined: Mon Sep 29, 2008 3:48 pm
Has thanked: 0 time
Been thanked: 0 time


Return to PL/I

 


  • Related topics
    Replies
    Views
    Last post