views:

46

answers:

2

I am using version 8.71 and my OS is Windows XP SP3. The error I get is as follows:

Error: /undefinedfilename in --showpage--
Operand stack:
   1   true
Execution stack:
   %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostringval-
-   2   %stopped_push   --nostringval--   --nostringval--   --nostringval--   fa
lse   1   %stopped_push   1878   1   3   %oparray_pop   1877   1   3   %oparray_
pop   1861   1   3   %oparray_pop   --nostringval--   --nostringval--   2   1
3   --nostringval--   %for_pos_int_continue   --nostringval--   --nostringval--
  1761   0   9   %oparray_pop   --nostringval--   --nostringval--
Dictionary stack:
   --dict:1165/1684(ro)(G)--   --dict:1/20(G)--   --dict:75/200(L)--   --dict:75
/200(L)--   --dict:108/127(ro)(G)--   --dict:288/300(ro)(G)--   --dict:22/25(L)-
-   --dict:6/8(L)--   --dict:26/40(L)--
Current allocation mode is local
Last OS error: No such file or directory
GPL Ghostscript 8.71: Unrecoverable error, exit code 1

Close this window with the close button on the title bar or the system menu.

The value of sOutputFile that I pass is something like 234 characters plus %03d so the file name effectively generated is 237 characters.

A: 

I think because of OS/FS limitations. See this answer for numbers

RC
You're right. When I don't specify a placeholder (%03d), 255 characters in sOutputFile produces the same error. What's weird though is that the limit if there's a placeholder is just 237 (including %03d).
Chry Cheng
The limit is on the path (full path), thats probably why you get 237
RC
I don't understand. When expanded, the effective file name should be no more than 240.
Chry Cheng
+1  A: 

subst is your friend when requirments call for stupidly long paths

squig