; macro to page a document ; :pr "#1/#13/ *** ÐÁÇÅÎÕÍ ÍÁÃÒÏÆÅÁÔÕÒÅ ***#13/#13/" :pr "This macro will number the pages of a document from #13/" :pr "1 to 30,000. The following limitations apply to #13/" :pr "page numbering done with this macro: #13/" :pr " #13/" :pr " ** The document to be printed must be in a disk #13/" :pr " file. It cannot be in your work space. #13/" :pr " #13/" :pr " ** Page numbering must be embedded in a .H #13/" :pr " statement with the ££ notation. #13/" :pr " #13/" :pr " ** The .Y statement for a title must come #13/" :pr " immediately before the .H statement specifying #13/" :pr " the title. #13/" :pr " #13/" :pr "#13/Do you want to pause " :in "between pages? (0=no, 1=yes) " %7 :IN "#13/Enter the number of the first page: " %1 :%9 = $4 :on -1 125 ;set up the files ; loop here to get the next file :%9 = $4 :on -1 145 ;get the next file name :sl %A %9 :on %9 1000 1000 / ;done? ro/%A/ :on $0 /+4 / /+4 ;if can't be opened, exit :pr "#1/file %A can't be opened. Hit a key to exit." :in :on -1 1000 R10 ;read in any dot command header J1/E ;install the Y-table fh fy h0/h2 ;put the title and y-tab in the hold T/F/F1 :%3 = $3 :%2 = 0 ; loop here for another page t/F/F1 :on $0 /+1 / /+1 ;file open? :on ?-3 25 25 / ;no more file? :on $0 / /+1 / ;if file open, read some e/r120-$3 ;read enough for 100 lines :on $0 60 / 60 ;end of file reached? e/b1 :on ?-46 /+3 / /+3 ;see if a .e here :mc $2+1 :on ?-69 / 60 / ;see if an e :on ?-101 / 60 / f1/s//<.E