• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Page Numbering Error in Editing PS File

New Here ,
Jul 17, 2013 Jul 17, 2013

Copy link to clipboard

Copied

I have a three page PS file. In order to save printing cost I am trying to compress it in 1st Page (i.e in one Page).

I converted it into one page, However I am encountered with one Error 'No Page Numbering Available'

I am using GS View to see Post Script file. The fisrt page looks fine as I needed. However when I click for the next page, it comes empty (In fact it should not come) and when I click back, it gives error 'No page Numbering available'

Kinldy Guide what text I have to insert/Delete and Where ?

Here's my original PS File

https://www.dropbox.com/s/5yucai4bmc5so4u/Original-1019300445.ps

Here's my Compressed Ps File

https://www.dropbox.com/s/8zlamtw02k1f8fq/Compressed-1019300445.ps

Thanks

TOPICS
Programming

Views

8.7K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Jul 25, 2013 Jul 25, 2013

Have you even opened the PostScript Language Reference Manual? Comments are a normal part of PostScript. Anything starting % is a comment (but avoid %% and %! for they have special meanings). Be sure not to accidentally break the DSC comments (don't add in the middle of a stream of special purpose comments).

Votes

Translate

Translate
Explorer ,
Jul 25, 2013 Jul 25, 2013

Copy link to clipboard

Copied

Code Box

You can insert any comments any where across your code - top middle bottom  etc

As long as you start the comment with % 

you can even put the comment in dedicated line or even  at the endof the line

For example

% this is the part of sssss  ssssssss

0 30 moveto  %  this is the location of  bla bla 

better not use  %%  for comments, although it will not generate any problem

Any thing after the %%  or %  it will be considered as comment   - unless in case of DSC which begin with %% and it must be according to Adobe supplementary book for DSC.  and it should be in dedicated line

e.g.

%%Pages: 1

Cheers

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 27, 2013 Jul 27, 2013

Copy link to clipboard

Copied

Sir, Encountered with another typical problem.

When i see the ps file in normal mode, it looks fine. When I click on GS view to go to next Page the next page is rendered. However when I click on Zoom In/Out Buttons on Page two, GS view generates error.

I can back and forth in page 1-2-3 but when I click on Zoom button on page 2 or 3 it gives error. It does not such error on page one.

What Editing is required and Where ?

Here is my Ps file

https://www.dropbox.com/s/cy3yhfl1y18bt0j/1021264014.ps

Here is the error which I got when I zomm in or Out in page two or three

GSview 5.0 2012-01-17
Unknown in Comments section at line 2:
%Creator: iECCM

Unknown in Comments section at line 3:
%Version: 0.1

GPL Ghostscript 9.07 (2013-02-14)
Copyright (C) 2012 Artifex Software, Inc.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
Displaying DSC file C:/Users/AO WTR/Desktop/1021264014.ps
Displaying page 1
Can't find (or can't open) font file %rom%Resource/Font/ArialMT.
Can't find (or can't open) font file ArialMT.
Can't find (or can't open) font file %rom%Resource/Font/ArialMT.
Can't find (or can't open) font file ArialMT.
Scanning c:\psfonts for fonts... 0 files, 0 scanned, 0 new fonts.
Can't find (or can't open) font file %rom%Resource/Font/ArialMT.
Can't find (or can't open) font file ArialMT.
Can't find (or can't open) font file %rom%Resource/Font/ArialMT.
Can't find (or can't open) font file ArialMT.
Querying operating system for font files...
Didn't find this font on the system!
Substituting font Helvetica for ArialMT.
Loading NimbusSanL-Regu font from %rom%Resource/Font/NimbusSanL-Regu... 3168784 1825089 3336904 1721832 2 done.
Can't find (or can't open) font file %rom%Resource/Font/Arial-Bold.
Can't find (or can't open) font file Arial-Bold.
Didn't find this font on the system!
Substituting font Helvetica-Bold for Arial-Bold.
Loading NimbusSanL-Bold font from %rom%Resource/Font/NimbusSanL-Bold... 3208976 1879336 3336904 1738363 2 done.
Displaying page 2
Can't find (or can't open) font file %rom%Resource/Font/ArialBlack.
Can't find (or can't open) font file ArialBlack.
Didn't find this font on the system!
Substituting font Helvetica-Bold for ArialBlack.
Can't find (or can't open) font file %rom%Resource/Font/Arial-Italic.
Can't find (or can't open) font file Arial-Italic.
Didn't find this font on the system!
Substituting font Helvetica-Oblique for Arial-Italic.
Loading NimbusSanL-ReguItal font from %rom%Resource/Font/NimbusSanL-ReguItal... 3289360 1971779 3336904 1865960 2 done.


GPL Ghostscript 9.07 (2013-02-14)
Copyright (C) 2012 Artifex Software, Inc.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
Displaying DSC file C:/Users/AO WTR/Desktop/1021264014.ps
Displaying page 2
Scanning c:\psfonts for fonts... 0 files, 0 scanned, 0 new fonts.
Can't find (or can't open) font file %rom%Resource/Font/ArialBlack.
Can't find (or can't open) font file ArialBlack.
Querying operating system for font files...
Didn't find this font on the system!
Substituting font Helvetica-Bold for ArialBlack.
Loading NimbusSanL-Bold font from %rom%Resource/Font/NimbusSanL-Bold... 3168784 1826211 4004872 2388387 2 done.
Error: /undefined in F1
Operand stack:

Execution stack:
   %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostringval--   2   %stopped_push   --nostringval--   --nostringval--   false   1   %stopped_push   1932   1   3   %oparray_pop   1931   1   3   %oparray_pop   1915   1   3   %oparray_pop   1803   1   3   %oparray_pop   --nostringval--   %errorexec_pop   .runexec2   --nostringval--   --nostringval--   --nostringval--   2   %stopped_push   --nostringval--
Dictionary stack:
   --dict:1182/1684(ro)(G)--   --dict:0/20(G)--   --dict:151/200(L)--
Current allocation mode is local
Last OS error: No such file or directory

--- Begin offending input ---
%%Page: 2 2
<</Duplex true /Tumble false /ManualFeed false /MediaPosition 1>> setpagedevice
g n
/Fn3{d I/ArialBlack F}b/F13{/I 15.0 Fn3}b
F13 B (BHARAT SANCHAR NIGAM LIMITED)301 805 y
G
1 w1 594 774 2 774 L
g n
F1 B (Account Number    1021264014)27 789 w
G
g n
F1 B (Invoice Number    10212640140008)566 789 x
G
g n
F1 B (Invoice Date    06/02/2013)229 789 w
G
E 16 571 75 -12 i
B 90 559 16 559 L
/F14{/I 6.3 Fn2}b
F14 (STD)18 562 w
E 90 571 43 -12 i
B 133 559 90 559 L
E 133 571 30 -12 i
B 163 559 133 559 L
E 163 571 16 -12 i
B 179 559 163 559 L
E 179 571 26 -12 i
B 205 559 179 559 L
E 205 571 75 -12 i
B 279 559 205 559 L
E 279 571 43 -12 i
B 323 559 279 559 L
E 323 571 30 -12 i
B 352 559 323 559 L
E 352 571 16 -12 i
B 368 559 352 559 L
E 368 571 26 -12 i
B 394 559 368 559 L
E 394 571 75 -12 i
B 469 559 394 559 L
E 469 571 43 -12 i
B 512 559 469 559 L
E 512 571 30 -12 i
B 542 559 512 559 L
E 542 571 16 -12 i
B 557 559 542 559 L
E 557 571 26 -12 i
B 583 559 557 559 L
(Date          
--- End offending input ---
file offset = 10351
gsapi_run_string_continue returns -101

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 27, 2013 Jul 27, 2013

Copy link to clipboard

Copied

You have not done anything with the DSC, so of course it is still wrong!

Please read my reply #14 again.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 27, 2013 Jul 27, 2013

Copy link to clipboard

Copied

I have read your reply, but my understanding on PS is very less. I dont know what is better and right. Whether to Keep DSC or Not ?  Kindly Guide in detail and give solution to the above problem .

Also please suggest some simple online Book to start up with Post script

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 28, 2013 Jul 28, 2013

Copy link to clipboard

Copied

If you want to keep DSC you must first fully understand it. This does not seem to be a path you are ready to follow. So you must disable DSC by the method I stated.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 28, 2013 Jul 28, 2013

Copy link to clipboard

Copied

I tried to put %! , but was not able to, perhaps I have not understood properly that how to disable DSC in my PS files.

Can you give a example that how should I disable DSC.  here is my file.

https://www.dropbox.com/s/5yucai4bmc5so4u/Original-1019300445.ps

Second and very important, what is advantage or disadvantage of  disabling DSC ? What effect it has in final viewing and printing my post script file,

I saw that in my original files also I have the same errors as I described above. The file linked above is the original file as downloaded. Is this file is also having the same DSC problem ?

Kinldy edit the above file and tell me what changes have been made to make it error free.

Thanks

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jul 28, 2013 Jul 28, 2013

Copy link to clipboard

Copied

Perhaps you should consider another software to generate that ps files with more flexability to compress or expand the pages an dof course other personalization!

What Software responsible for generating that file?

Why don't you use

Lytrod.com

DCS-System.com

Elixir.com

Objectivelune.com

Streamserve.com

etc

Cheers

Adam

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 28, 2013 Jul 28, 2013

Copy link to clipboard

Copied

No sir, files have been generated in some server machine. I am not aware of It. I am a VFP programmer just trying to edit the location of text in original ps file  so that some pages could be saved andm Extracting some Data from PS files (my PS files are Bill Files) to generate some extra reports.

Using VFP cursors I could take all text of PS files and can re write it again, that is all what I am doing

Seems that the original files i am using itself contains DSC Error. The file I have posted as Link above is the original file and I found the same Zoom error on page 2 and 3 in it also, so I thought if I could correct DSC in my edited version.

I put %! at the begning of the file , the zoom error was not comming but, I could not back and forth between pages 1-2-3 and when I do so it gives error as 'Page Numbering Not available'

So i was looking for one complete DSC compitible Error free file of my file linked above so that I observe changes and do corrections accordingly.

Anyway Thanks a lot all the help

Regards

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 28, 2013 Jul 28, 2013

Copy link to clipboard

Copied

You insist that your problem is a simple one. This is common when people don't understand the complexity of the task. No, it is only simple to describe, not simple to do. You say  just trying to edit the location of text in original ps file but the word "just" suggests an easy or simple task.   I am an experienced PostScript programmer, I might go so far as to say I'm an expert. But repaginating a PostScript file is, in the general case, not just difficult, it is impossible. Some PostScript doesn't work that way. Some does but is hard. And some is, by sheer good luck, very simple. So the general solution to the problem does not exist. The specific solution for one PS generator may exist and may even be simple.

gives error as 'Page Numbering Not available'. This is not an error, it's normal condition. The message is exactly right. Your software is using "page numbering" to mean "DSC". But since you have moved information between pages, and do not know how to fix the DSC, you must remove it otherwise even worse effects will happen.

To add DSC properly needs a deep analysis of the file. It is not even always possible (though sometimes it is very easy).

It is easy to move the %%Page: comments so they are correct, but much harder to keep page independence (deep analysis needed).

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 29, 2013 Jul 29, 2013

Copy link to clipboard

Copied

I found the specification of DSC here: http://partners.adobe.com/public/developer/en/ps/5001.DSC_Spec.pdf

Here are some PostScript resources. PostScript programmers, whatever introductory material they might have, always need the PostScript Language Reference Manual. It's a 1000 page book, so I prefer to buy the book rather than struggle with the PDF. http://partners.adobe.com/public/developer/ps/index_specs.html

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jul 29, 2013 Jul 29, 2013

Copy link to clipboard

Copied

LATEST

No need to buy the PostScript Language Reference Manual. ** it is free **

and can be downloaded from Adobe

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 28, 2013 Jul 28, 2013

Copy link to clipboard

Copied

Sorry, I do not see the difficulty. No, I will not edit your file for you! The end result is an extra line before the current first line and it needs to contain only these two characters


%!

The advantage of disabling it (or fixing it) is that your file will not be broken. This in turn should make tools which use DSC (like many PS viewers) work properly, because if the file starts

%!PS-Adobe-3.0

instead, they assume the DSC is all correct - and it isn't because you have changed the file around.

A file starting

%!

%!PS-Adobe-3.0

is fine and is not DSC.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines