Not really sure if this is the right place for this question, however I am pulling my hair out and wanted to see if anyone can help me. Basicaly I am trying to configure my Silverlight App to connect a local scanner, aquire the image and save it to the databse.
I have prety much all of it working, however the WIA.ShowAquireImage is genarating images in Bitmap and I am trying to convert them to JPEG before saving it to the SQL DB. I have implemented this sode:
If imageFile.FormatID <> wiaFormatJPEG Then
Dim ip As Object = AutomationFactory.CreateObject("WIA.ImageProcess")
ip.Filters(1).Properties("FormatID").Value = wiaFormatJPEG
ip.Filters(1).Properties("Quality").Value = 20
imageFile = ip.Apply(imageFile)
However I am getting ComAutomation_BadParamCount, Argument: FilterID. Can anyone help me or at least point me in the right direction?