Page 1 of 1

Cannot load PDF

Posted: Mon Feb 09, 2009 11:53 am
by hansellh
Hi Guys,

I'm receiving an "Unknown Format" error when the code gets to the following LoadBitmap line

I am running ghostscript 8.60, and i've so far attempted to use glax 2.2, 2.7 and 2.90. I've attempted to load three different PDFs, all of which open fine in Adobe, however I don't seem to be able to get them to load here.

Code: Select all

        internal static void Generate(string pdfFile, string imageFile)
            log4net.LogManager.GetLogger("Thumbnailer").InfoFormat("Creating thumbnail {0} for {1}", imageFile, pdfFile);

            GflAx.GflAxClass g = new GflAx.GflAxClass();
            g.EpsDpi = 72;
            g.Page = 1;
            g.SaveFormat = GflAx.AX_SaveFormats.AX_JPEG;
            g = null;

            log4net.LogManager.GetLogger("Thumbnailer").InfoFormat("Created thumbnail {0} for {1}", imageFile, pdfFile);
Is there something I am missing here or something I can do to fix this?


Re: Cannot load PDF

Posted: Mon Feb 09, 2009 1:09 pm
by xnview
And xnview can load them? Do you have tried with AFPL version of ghostscript?

Posted: Mon Feb 09, 2009 1:14 pm
by hansellh
XNView can load the pdfs fine. I do get a multiple page warning, but they are opened fine. They also save ok as jpegs from XNView


Posted: Mon Feb 09, 2009 1:44 pm
by xnview
Strange, perhaps could you send me the pdf to test?