This project has moved and is read-only. For the latest updates, please go here.

New version will not open file

May 31, 2014 at 8:51 AM
I'm having problems getting any version after to open an eps. The latest version ( is saying ImageMagick.MagickDelegateErrorException: Magick: FailedToExecuteCommand `"gswin32c.exe". Do I need to install something different to make that work? Alternatively, is there a way to convert an eps to a png without losing transparency in the older version?

Jun 1, 2014 at 4:22 PM
Did you install Ghostscript? Your error message suggest that you did not do that. You can download Ghostscript here:
Jun 4, 2014 at 5:07 PM
OK I was hoping to avoid that, but that was the issue.. The new version didn't solve my transparent background issue though. They always come out white. I see a convert command referenced in several places, but do not see how to use it with a MagickImage.
Jun 4, 2014 at 5:32 PM
Here is what I have now based on this thread.

I'm still getting white backgrounds though.

        MagickReadSettings settings = new MagickReadSettings();
        settings.Format = MagickFormat.Eps;

        settings.ColorSpace = ColorSpace.RGB;
        settings.Density = new MagickGeometry(72, 72);

        using (MagickImage img = new MagickImage(fileName, settings))
            //tried all of these
            img.BackgroundColor = Color.Transparent;
            img.Transparent(new MagickColor(Color.Transparent));

            img.Format = MagickFormat.Png;
            byte[] bytes = img.ToByteArray();
            Stream s = new MemoryStream(bytes);
            s.Position = 0;
            return s;
Jun 4, 2014 at 5:33 PM
Not trying to yell.. Not sure why it made that big.
Jun 4, 2014 at 9:38 PM
Edited Jun 4, 2014 at 9:39 PM
Can you try this:
using (MagickImage img = new MagickImage())
  img.BackgroundColor = MagickColor.Transparent;
  img.Read(fileName, settings);
And if this does not work, can you share your EPS file so I can run some tests with it?
Jun 5, 2014 at 1:43 AM
I just replied to you.. Thank you for your assistance!
Jun 5, 2014 at 8:01 PM
Your files are CMYK. The vector files don't have a background and the cmyk32 (8 bits per channel) output device does not have transparency so it makes the background white. If you want to add transparency you should set the ColorSpace to sRGB in the MagickReadSettings:
MagickReadSettings settings = new MagickReadSettings();
settings.ColorSpace = ColorSpace.sRGB;

using (MagickImage image = new MagickImage("", settings))
Jun 5, 2014 at 8:50 PM

Hi Dirk,

I still get the same thing. The Porsche file comes out with a white background and the other two do not import at all. Do these work for you? I’m using the any cpu version version with Ghostscript 9.14 64 bit. It’s an ASP.NET page.

Any ideas?

Jun 5, 2014 at 9:53 PM
Edited Jun 6, 2014 at 7:39 AM
Check your e-mail, I left you a message.

EDIT: The problem seemed to be related to IIS Express. Switching to IIS resolved the issue. We don't know the reason yet but I will try to figure that out later.