If you are trying to read a PDF without using the PdfDecoder directly and you want DotImage to discover the type automatically, you need to register the PdfDecoder so that DotImage knows that it can use it to try to read a file. If you do not do this, you will always get an Unrecognized Image Type exception when trying to open a PDF.
You would need to do this if you had code like this:
AtalaImage img = new AtalaImage("mydoc.pdf");
To read this file, DotImage uses its list of registered decoders and asks each one in turn if it can read the passed in file. Here are the steps to registering the PDF Rasterizer:
- Request an Eval license of the PDF Rasterizer if you don't already have a license
- Add a PDF Rasterizer reference to your project
- Add this code so that it runs before any code that tries to read a PDF -- we recommend that you put it somewhere so that it will run once in your whole program, like in a static constructor for your main form.