I am trying to make a UWP app that allows users to quickly set a few settings and then scan a document. One of the settings I want to give the user is to choose between a Tiff or a PDF. When I set the file format to PDF which is in the enum list of File Formats you can set to a scanner configuration I am getting an exception thrown. The exception is "The parameter is incorrect"

Other applications are able to scan as a PDF with my type of scanner (Fujitsu fi-6130) but my application will not, I even tried a long shot of making sure my locally installed Adobe was up to date not that I thought those two would interact. When I set the format to a Tiff, or png I do not get any error and they scan no problem.

I have followed the documentation to configure a scanner correctly and PDF is listed as an available Format here ImageScannerFormat Documentation

// MyScanner is an instance of ImageScanner class
MyScanner.FeederConfiguration.Format = ImageScannerFormat.Pdf;

It fails at this line, not when I try to scan files, Tiff, PNG, and Bitmap have all worked, not sure about the other available format because I have not tested them.

I expect the scanner to accept PDF as a file format and to then scan the files as a PDF.

Let me know if you have any questions, thanks!

0 Answers