Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Error saving figures in pdf format

55 views
Skip to first unread message

Vesh

unread,
Sep 8, 2010, 3:30:13 AM9/8/10
to
Hello,

I have been trying to save a figure that MATLAB generates in a pdf format with the height and width of the figure adjusted in the print preview to be 4" by 4". But I have been getting the error
"Error using ==>hgexport
Error using ==> print
Error using ==> \graphics\private\ghostscript
Problem calling GhostScript. System returned error"

There have been reporting of this problem in the past but no effective solution posted.

Any suggestions is greatly appreciated.

Thank you

John

unread,
Sep 8, 2010, 4:18:06 AM9/8/10
to
I don't know whether or not it will solve your problem, but try using the exportfig utility (from the File Exchange). It produces much nicer figures, and allows better control over fontsize, DPI, etc.

"Vesh " <vesh_...@hotmail.com> wrote in message <i67e25$mrp$1...@fred.mathworks.com>...

Vesh

unread,
Sep 9, 2010, 2:33:33 AM9/9/10
to
Thanks John.
I have been looking at that utility also. Hope it solves the problem from a different approach. Thanks again for your response anyway.


"John " <iwillnotserve+f...@gmail.com> wrote in message <i67gru$uh$1...@fred.mathworks.com>...

Christian Karlsson

unread,
Sep 26, 2011, 8:39:13 AM9/26/11
to
Hi,

I solved my problems with printing PDF files by rechecking my path I was in. As I had "%" in my path it worked fine producing .fig but failed producing .pdf. When removed it works fine with both. I guess the printer does not like the '%' which is probably reserved operator in the printer function. There might be other signs that can cause this issue as well.

//CK


"Vesh" wrote in message <i67e25$mrp$1...@fred.mathworks.com>...
0 new messages