About PostScript errors
Sorry, almost all the links to other people's web pages are now broken. Why can't they stay still!
Quick contents
Introduction - what is an error?
What is the error?
Use an error handler
Still no error details?
Things to try first
Checking for corrupt graphics
About us
PostScript error details (alphabetical
by error name)
HP Laserjet Error codes (30 PS ERROR nn)
Introduction - what is an error?
This is intended for people who have to try and deal with PostScript errors. You don't need to know anything about PostScript, except that it is a language that gets sent to a printer.
By 'errors' I mean specific errors detected by a PostScript printer, that make it stop printing. This won't help you if the results are complete, but not what you expect.
Good information on errors is hard to come by. The information here may help. It is long and detailed, and best used as a reference.
Still, be prepared for a long struggle. Sometimes a file simply cannot be printed on a particular printer, particularly if it is old or has limited memory. (The amount of memory supplied by default with many printers is not adequate for complex graphics or using many fonts).
Some people will be dealing with PostScript files sent to them, that they must try to print; others will be generating the PostScript themselves. Not all of the advice in this document can be followed by both groups. Although I refer to 'printers' throughout, you might be using a printer, a printing or previewing package on a PC or workstation, or a high-end typesetter.
This file is definitely not intended to help people writing their own PostScript. The discussion is confined to errors likely to be found when a program writes the PostScript on your behalf. If writing PostScript you will need a good manual, and lots of patience!
A particularly unpleasant source of problems is bugs, either in the programs that write the PostScript, or in a few cases in the PostScript interpreter itself. As bugs can cause anything to happen, this document may not be much use either, but I have included information on some bugs that have been discovered in common software.
Good luck! You may need it.
What is the error?
PostScript errors are reported in various ways. Before you can get anywhere with a problem you need to know the error name and offending command. For instance
Error: limitcheck; Offendingcommand: clip
Many people skim this information and say that they have received "an offending command error", but this information by itself is worse than useless. Accurate information is the first step in solving any problem.
Sometimes the information appears on a printed sheet, and this often has supplementary information. Keep it, it may be useful. The information might not be presented exactly as above. For instance the Microsoft Windows PostScript driver would present the above error as:
Offending Command = clip Error = nametype : limitcheck
Given the error and offending command, you can proceed straight to looking them up in the error details below, but you may want to return and check the rest of the advice below.
Use an error handler
What if you don't see an error message like this? One solution is to download an error handler to the printer. This is a special file which, once sent to the printer, sits there until the printer is switched off. When an error happens it prints out an extra page of information. Sometimes the error handler is included inside a job, and does not sit in the printer.
Many applications or PostScript printer drivers include an option 'download error handler' or similar. In Microsoft Windows there is an option 'Print PostScript Error Information' hidden under Advanced printer options. Always use it. Note, however, that the original Microsoft Windows 3.1 PostScript driver had an error that prevented the error handler from working.
One error handler can be obtained from Adobe, the inventors of PostScript, by downloading the ehandler.ps file. (Note: this file has been changed by Adobe, and appears to be a ZIP file now).
Still no error details?
Are you sure you have an error? A common cause of problems is trying to print an encapsulated PostScript (EPS) file. These are not designed to print and may produce nothing at all, or a completely blank sheet.
The correct use of EPS files is to be embedded in other applications, which then take care of printing.
Things to try first
Before you look into the error in any great detail, it is often worth trying again (especially for error name undefined). Is the problem repeatable? Do you get exactly the same results, or lack of them, each time?
If a problem is not exactly repeatable, you probably have a problem where files are being corrupted. This could be on your disk, as a result of cabling (check cables are tight and undamaged; remove any switch boxes or extensions; use a different cable if possible), or, if the printer is connected by serial rather than parallel cable, the serial port setup could be wrong.
Corruption can occur even before the file is printed - say as it is read from a network. Different types of network, and network software, have different reliabilities. See the next section for how to check for corrupt graphics.
Sometimes switching a printer off and on will make a difference. This probably means that the printer is slowly running out of memory, but if you share the printer, it is not impossible that someone else if affecting its setup (they would have to be pretty conversant with PostScript, though). Beware of using a font downloader - these use up printer memory.
It is often worth splitting printing into two processes. First, print to file (note that some applications allow you to save as EPS - this is not the same as printing to file). Now send the print file to the printer. Do you get the same error consistently? This not only helps to establish whether the problem is getting in before or after printing, it gives you a file to use as evidence if you need to take the problem further.
Checking for corrupt graphics
Even if the results are consistent, corruption could be to blame. Check the error descriptions below to see if corruption is listed as a possible cause. If so, and you are working composing pages on screen, check for corrupt graphics (especially EPS graphics).
- Make a copy of your file (important!)
- Remove all of the graphics. If the file prints up to a particular page concentrate on that page. It doesn't matter how small a graphic is.
- If you find that removing all the graphics from a particular page means it now prints (albeit incomplete) add the graphics one at a time. If there are a great many try to isolate them by making a fresh copy of the original and removing half of them. If the file still fails, remove half of the remainder, and so forth.
- If the file apparently works with either half of the graphics removed, first check very carefully that you have not been overlooking a particular graphic. If you are sure, you are probably running out of printer memory.
The key to solving, or at least identifying, problems is to be systematic. If you are in a muddle, don't bother to write down error messages, or won't devote the time needed, you probably won't solve the problem and you might as well give up now.
Finding out more
What if this doesn't help?
The fullest description of PostScript errors is in the book PostScript Language Reference Manual, 2nd edition, Addison Wesley, ISBN 0-201-18127-4. This will help only people who want to understand the PostScript.
It is just possible, but not very likely, that the printer or your computer is faulty. More likely, but still not very, is the possibility that your software is damaged, and reinstalling it will help.
There may be a bug in the program you are using, or possibly even in the printer. If you are convinced of this, you will need to take this up with the relevant parties.
Otherwise, you may have to seek expert help, or try to produce the information in a different way.
About us
Quite Software (that's us!) offer a product called PSAlter, which allows PostScript to be debugged or previewed using Microsoft Windows. PSAlter does offer greatly improved error messages, and the chance to see exactly where in the program the problem has occurred- often in graphical terms. This may be of great interest to PostScript programmers, but don't view it as the universal solution to all PostScript errors, especially if you haven't learned any PostScript - there is a difference between knowing all about where an error occurs, and knowing how to fix it. But, it certainly helps in a proportion of cases and can speed up the process of identifying a damaged graphic enormously. Why not read about PSAlter and decide if it it is likely to help you.
We are sorry, but we don't have the time or resources to offer a free consultancy service. Please, no unsolicited PostScript files. We do welcome suggestions for improving this page, our other PostScript pages or anything else in our site.
A good place to get help with PostScript on the internet is the comp.lang.postscript usenet group.
Error details
What are the PostScript errors? There are not very many error names, and this is part of the problem. Each name usually covers a number of different problems. The error names are as follows.
configurationerror dictfull dictstackoverflow dictstackunderflow execstackoverflow interrupt invalidaccess invalidcontext invalidexit invalidfileaccess invalidfont invalidid invalidrestore ioerror limitcheck nocurrentpoint rangecheck stackoverflow stackunderflow syntaxerror timeout typecheck undefined undefinedfilename undefinedresource undefinedresult unmatchedmark unregistered VMerror
If the error is of the form 30 PS ERROR nn look it up in the list of HP Laserjet error codes.
Error -8133 is sometimes reported by Macintosh users. This just means "a printing problem occurred" and you will need to go further to identify the PostScript error.
configurationerror
Occurs when a device request cannot be satisified. For instance, the PostScript file was produced for an A4 page size, but there is no A4 paper available. Device mismatch.
dictfull
A dictionary (used to store PostScript variables) is full. Usually this is userdict, the main dictionary. Some printers allow the size of userdict to be increased. Should not occur with PostScript level 2. This patch may help, added to the PostScript:
% Insert after %%BeginSetup if any, else after initial % lines.
/real-dict /dict load def
/dict { dup add real-dict } def
userdict length dict begin
dictstackoverflow
Too many dictionaries used simultaneously. Should not occur with PostScript level 2. Usually caused by nested graphics (one graphic placed inside another, inside another...). Simplify.
dictstackunderflow
The program used an end instruction at the wrong time. Corruption.
execstackoverflow
PostScript too complicated (specifically, too many active subroutines). Rarely seen; unlikely to occur in PostScript level 2 unless stuck in an infinite loop. Can be caused by badly written PostScript headers to do jobs like print 2-up.
interrupt
Program was interrupted deliberately. Not usually an error. If you aren't expecting this error, and you didn't interrupt, there may be binary data sent to a printer that can't handle it - specifically Ctrl+C (ASCII 003), or corruption.
invalidaccess
Program tried to access data that is not allowed, like the inside of a font. Rarely seen.
invalidcontext
Display PostScript only. Should not be seen in a printer.
invalidexit
Program used exit where it is not allowed. Rarely seen.
invalidfileaccess
Tried to access a file in a way not allowed (e.g. write a read-only file; create a file in a read-only directory). Some PostScript interpreters disallow all file writing for security reasons.
invalidfont
Something wrong with a font. Try using different fonts to identify which one is at fault. Could be corruption of a downloaded font.
invalidid
Display PostScript only. Should not be seen in a printer.
invalidrestore
Program used exit where it is not allowed. Rarely seen, except when PostScript has been modified in an attempt to fix a problem, leaving data on stacks.
ioerror
A real I/O error may have occured (e.g. a disk fault, or problem controlling a printer). In level 2 PostScript this can also be bad information for a filter, so this could mean corruption.
limitcheck
The printer has reached an internal limit. Some limits are fixed, some depend on memory. In level 2, there are fewer fixed limits.
Most common cause is a path too complicated: for instance a cutout, or a drawn outline; also outlined text. Using the 'magic wand' in Adobe Photoshop it is possible to get a very complicated clip path. It is likely to be a path length if offending command is one of arc arcn arct arcto charpath clip closepath curveto flattenpath eoclip eofill fill lineto moveto rcurveto rlineto rmoveto stroke strokepath.
Simplify. Increase available memory, especially if level 2 (not all level 1 printers will increase path limit if memory is increased). See entry for VMerror for hints.
The limitcheck error can also mean that there is not enough memory to do the page size and resolution requested. Typical RAM requirements for letter/a4 paper are 1 MB at 300 dpi; 4 MB at 600 dpi; 7 MB at 800 dpi. Double for A3/11x17 paper. Double for duplex (double sided). Quadruple for colour. This is just to hold the page; more will be needed (at least 1 MB) for fonts, paths, and other things.
nocurrentpoint
A program tried to do something relative to the current point, but it wasn't set to anything yet. For instance attempting to write text, without saying where on the page it is to go. Corruption.
rangecheck
A value was outside the acceptable range for the printer, or just wrong (like an attempt to get the fifth character from a four character string). Could be a file tested on one printer but not suitable for yours. Also look for very large values or objects well off the page. Possibly, corruption. The offending command may be a clue what sort of value is out of range.
If offending command is getinterval, the PostScript is produced by Adobe Acrobat, and the interpreter is not made by Adobe, you have found a bug in Acrobat. You can patch the file by adding:
% Patch for Acrobat bug - add after initial %% lines /version (888.000) def
Can be caused by sending a level 2 file to a level 1 printer, especially if offending command is one of colorimage image imagemask.
stackoverflow
Too many items on the operand stack. In PostScript level 1 there is a fixed limit; in level 2 the limit is much higher. Can be caused by a program only tested with level 2. If the error occurs only once documents get past a certain level of complexity, there might be subtle errors that gradually fill up the operand stack - try printing fewer pages, if you can.
stackunderflow
Attempt to remove something from the PostScript stack when it isn't there. Can be caused by corruption or when PostScript has been modified in an attempt to fix a problem.
syntaxerror
The PostScript is not understood. Few situations cause this error, and they almost all indicate corruption. The only likely alternatives are using the level 2 << symbol in a level 1 printer, or mismatched { } brackets in a file, possibly caused by attempting to fix it.
timeout
The printer is waiting for something to happen, but it didn't happen. A printer has three different timeouts, and it could be any one:
- Job timeout is not usually set, but means a job is taking too long.
- Manual feed timeout. Could this job be asking for manual paper feed? Are you sure? Word Perfect is especially prone to do this if the paper size is not set properly.
- Wait timeout. A job hasn't finished, but nothing has arrived in the printer for some time. Can be caused by the computer giving up, or being asked to do something else for too long. Also, some printers need a Ctrl+D character at the end of each job, which the printer driver should put there - this is likely to be the case if the timeout error follows a complete job. If adding Ctrl+D yourself, make sure it is not followed by a new line - it must be that very last character in the file. Many editors won't allow this.
typecheck
An operator was expecting objects of one type, but got a different type. Like finding a name instead of a number.
- Usually corruption.
- Can be caused by trying to use a level 2 file on a level 1 printer, if offending command is one of colorimage image imagemask settransfer status.
- If offending command is status, and the
file is printed from Acrobat Reader 3.01, then this is because
of a bug in Acrobat Reader 3.01 (or because Adobe have deliberately
dropped support for older printers, I don't know which). The
following code, downloaded to the printer, may fix it until switched
off:
%!
serverdict begin 0 exitserver % ***
mark /status load type /operatortype eq
{ { (xxx) status } stopped
{ $error /newerror false put /+@status /status load def /status
{ dup type /stringtype eq { pop false } { +@status } ifelse
} bind def } if } if cleartomark
You can include this inside the PostScript file if you prefer, just after the first group of % lines, but you MUST remove the line marked % ***. - If offending command is div this may be caused by a bug in Adobe Illustrator 7.0. If any EPS in the page was made with 7.0, open and save it again with Illustrator 7.01. This error does not always occur, even for the same EPS file. (In detail, code in Illustrator EPS files assumes the stack is empty on entry to the EPS file, which is not always true).
- If offending command is setflat this is caused by a bug in older versions of Adobe Photoshop, but reflects a real problem that should have been reported as for limitcheck - cutout too complicated, simplify.
- If offending command is setcolor and this is a PostScript interpreter not from Adobe, and part of the job was produced by an old release of Aldus Freehand, this is an incompatability.
undefined
The printer found something it did not understand. The offending command should tell you what that is, and it may be gobbledegook.
- May be caused by corruption, especially if the command is junk.
- Is this an EPS file that you are copying to the printer? Don't, that's not what they are for.
- Might be a device mismatch, especially if the command is something like setduplex or setpagedevice
- If offending command is @PJL or %-12345X this file was indended for a Hewlett Packard printer. Either you have the wrong file, or you are sending a file via AppleTalk that wasn't meant to. Sometimes, but not always, removing the initial lines from the file will fix this.
- If offending command is pR this is often
a problem seen printing from Netscape with the Microsoft Windows
PostScript printer driver. Some releases of Netscape don't do
this. The possible fixes include using the Adobe PostScript driver
(AdobePS), and downloading the following patch file to the printer,
which will last until you switch off:
%!
serverdict begin 0 exitserver
/pR 0 def /pG 0 def /pB 0 def
You can also add the third (and only the third) line above to an existing PostScript file. - If offending command is ISOLatin1Encoding, the file may be intended for a level 2 printer. Can be caused by a bug in certain printer drivers, even if they know you have a level 1 printer.
- If offending command is a single unprintable character or apparently nothing at all, you may have a Ctrl+D in a file that is being printed in a context where it is not required (e.g. from a Macintosh or on certain Unix systems). Remove it - it will usually be the very first or last character (or both).
- If offending command is one of: colorimage currentcmykcolor currentcolorscreen currentcolortransfer setcmykcolor setcolorscreen setcolortransfer the information is intended for a colour printer or level 2 printer. Device mismatch, or check for a Use colour option in the application. Beware also of EPS files of colour photographs, though Adobe Photoshop produces files that are acceptable on level 1 monochrome printers too so long as "JPEG EPS" format is not used.
- Might be a level 2 file sent to a level 1 printer. There are over 100 new commands in PostScript level 2, but common ones that you might see in this context include currenthalftone currentglobal currentpagedevice setcolorspace setglobal sethalftone setpagedevice setstrokeadjust.
undefinedfilename
Could not find a file name used in the program.
- If you tested a PostScript file on your computer and called in files, then tried to send it to your printer, please think. How do you expect the printer to reach back and grab your files? (This is a surprisingly common error).
- If you are running the file on a computer, make sure you are in the same directory, and haven't removed any files.
- If you have changed computer, you might have to copy files across. Berate the author of the PostScript for not telling you.
- Some PostScript interpreters do not allow file access, for security reasons. And many printers do not implement file access at all. Some require an optional hard disk to be installed. Think again.
- Different interpreters have different conventions for accessing named files. Some will allow (abc.ps) while others might need (%os%abc.ps).
undefinedresource
Looking for a built-in resource (say, a set of procedures), that isn't there. Unlikely to occur, unless sending a file to the wrong device, or a badly configured one.
undefinedresult
Things like division by zero or the square root of -1. Less obviously, if a program scales everything down to a point this error will occur. For instance 1 0 scale will do this. Can be caused by a misguided attempt to change PostScript files; some programs may have an error that allows a scale factor of 0% to be used.
unmatchedmark
Missing an open bracket [ in a program. Corruption.
unregistered
"Should not occur".
VMerror
Printer out of memory. Fonts use printer memory: use fewer fonts, or use the fonts built in to the printer. Use a lower resolution, if available. Use a smaller page size, if applicable. If a printer, switch off and on. Don't download fonts you aren't using. If your printer driver offers a place to fill in the amount of memory, make sure it is accurate - and not the RAM size. Use the following program to find out the available VM:
%! % This program prints VM info (in bytes) /Courier findfont 14 scalefont setfont vmstatus 72 144 moveto (Total VM=) show 20 string cvs show 72 130 moveto ( Used VM=) show 20 string cvs show showpage
If running on a computer, reboot it if possible; try to reduce the number of other things going on at the same time. If system uses virtual memory, add more swap space, or free some disk space if swap space is automatic.
Finally, add more RAM to printer or computer as appropriate.
HP Laserjet Error codes
For no obvious reason, some HP laserjet printers (not HP4 or later) display an error number for PostScript errors, instead of a name. The message will always be of the form '30 PS ERROR nn' - nn is the error number, this message always starts with 30.
Here is the translation for each nn. 00 - dictfull; 01 - dictstackoverflow; 02 - dictstackunderflow; 03 - execstackoverflow; 04 - invalidaccess; 05 - invalidexit; 06 - invalidfileaccess; 07 - invalidfont; 08 - invalidrestore; 09 - ioerror; 10 - limitcheck; 11 - nocurrentpoint; 12 - rangecheck; 13 - stackoverflow; 14 - stackunderflow; 15 - syntaxerror; 16 - timeout; 17 - typecheck; 18 - undefined; 19 - undefinedfilename; 20 - undefinedresult; 21 - unmatchedmark; 22 - unregistered; 23 - VMerror.
In addition there are two special codes. 24 - executed quit operator; 25 - internal firmware error.
Back to the error index.
Back to the top.
To the PostScript pages.
To the PSAlter pages.
To Quite at home.
Last updated: 27 July 1999.
Feedback: feedback@quite.com
