Alternatives to WPD/WIA on Windows XP?
Posted
by Marek
on Stack Overflow
See other posts from Stack Overflow
or by Marek
Published on 2010-05-25T15:09:28Z
Indexed on
2010/05/25
15:11 UTC
Read the original article
Hit count: 830
WPD does not work correctly on Windows XP (SP1 if that matters), even if Microsoft states it does.
Problem with WPD:
IPortableDeviceManager.GetDevices
call does not find any devices on Win XP while it finds all connected cameras on Windows 7.
A few other people had this same problem with WPD not working on XP, no solution: 1 2
I have decided to reimplement the functionality using WIA.
Problem with WIA automation/WIA interfaces:
WIA automation
offers only silly dialogs when interacting with the camera - I need to rather do this from code- Programming against
WIA interfaces
is recommended to achieve lower level tasks with WIA. I have not found any samples how to use WIA interfaces from C# (also found some indication that this is not possible at all or at least very hard to do)
Thus I have looked at WIA 2.0 (wrapper around wiaaut.dll):
- I am getting HRESULT 0x80210006 (WIA_ERROR_BUSY) for the first time and then HRESULT E_FAIL all the time on Win XP while on Windows 7 the same code works without a problem.
I am getting out of options here... Can you recommend an alternative to provide the following features for cameras connected to the computer that works on Windows XP?
- sends a notification that a picture was taken
- allows to download the recently taken picture from the camera
© Stack Overflow or respective owner