You can't do it with the framework. You'll need to use something like
FreeImage (http://freeimage.sourceforge.net/) or Gfl Sdk
(http://pagesperso-orange.fr/pierre.g/xnview/engfl.html)
They're both unmanaged libraries, but you can use interop to call them.
FreeImage has 2 .NET wrappers available already, so it's probably the easier
way to go.
> I'm working on a project that have to load an display pcx-images in a
> PictureBox-control. When I try to load the file with Bitmap.FromFile I get
> an
> exception. Does anybody have an idea ?
Per - 04 Apr 2008 15:45 GMT
I found a wrapper for FreeImage that workt perfect. It's called
dotnetFireBall http://www.codeplex.com/dotnetfireball.
Image imageToSet = null;
Fireball.Drawing.FreeImage image = new FreeImage(@"c:\test.pcx");
imageToSet = image.GetBitmap();
pictureBoxImage.Image = imageToSet;
> You can't do it with the framework. You'll need to use something like
> FreeImage (http://freeimage.sourceforge.net/) or Gfl Sdk
[quoted text clipped - 8 lines]
> > an
> > exception. Does anybody have an idea ?
> I'm working on a project that have to load an display pcx-images in a
> PictureBox-control. When I try to load the file with Bitmap.FromFile I get an
> exception. Does anybody have an idea ?
Hi,
There is no support for PCX in the framework I think, in this case
you should try to find a third party control that allows it. I would
first stop by codeproject or some of the other code repositories to
see if there is a managed (and free) version around.
Ps:
If you find one please post it back here for the posterity :)