0

I am working of a PDF to image converstion. I found ghostscriptsharp which is a c# wrapper written for ghostscript. I used it and developed my application. Most thing if not all worked fine when i was testing with my console application.

After I integrated it into the webapp It just would not work. A quick search on the internet pointed me towards permission issues and framework incompatibility. but i have ruled them out.

gs32dll (ghostscript dll) is there in my webapplications bin folder. so no problems there either.

The webapplication is one project (webappLive) ghostscriptsharp is also a seperate project (GhostscriptSharp) - this has all the DLLImport and stuff one project will consume the GhostscriptSharp (GHInterface) - just calls the GhostscriptSharp

Any help suggestions will be appreciated.

P.S.: I have gone through all posts that has ghostscriptsharp tagged on SO, none of them came of any help

Adding Code:

try{
int result = InitAPI(gsInstancePtr, args.Length, args);
if (result < 0)
{
 throw new ExternalException("Ghostscript conversion error", result);
}    }

the result get a -100 (as per ghostscript that means fatal error)

Necrovore
  • 19
  • 3
  • Any exception messages? – Allan S. Hansen Dec 09 '15 at 07:05
  • Yes, following is the exception thrown by ghostscriptsharp: An unhandled exception of type 'System.Runtime.InteropServices.ExternalException' occurred in GhostscriptSharp.dll Additional information: Ghostscript conversion error – Necrovore Dec 09 '15 at 07:16
  • are you use visual studio ? I will show you example code how to. –  Dec 09 '15 at 07:23
  • Yes i use VS. I have posted the part where i get the exception in the Ghostscriptsharp source. – Necrovore Dec 09 '15 at 07:30

0 Answers0