Check if Device is available without Dialogs?
Posted: Tue Feb 17, 2015 1:24 pm
Problem:
- The DeviceManager has a list of installed Twain Devices. All installed Devices are listet in the Devices-List even if they are not connected.
- Example: I have installed the drivers for a Lide50 and for a DR-2050c. Now i see a lot of entries because every driver installs more than one device.
- Now i have the 2050c connected to the PC and this is the only Scanner-Device that is listed unter Windows -> Device Manager
- But the VintaSoft DeviceManager is giving me all Scanner-Devices that are possible: The Lide, some Webcams, the 2050c, ...
- If i try to open a Device that is not connected, i will get a Message that the device is not available. - Then i will run in the catch-code where i could handle that.
So: Is there any way to check for a Device being connected or not without getting any Windows-Messages/Dialogs?
My goal is: Only show devices that are really working, only devices that i could ".Open()" without error.
Edit: Oh, and i need this, because i like to Open() the Device to check if Duplex is available or not (I need this to offer this setting or to hide it from the user)
Thanks a lot
- The DeviceManager has a list of installed Twain Devices. All installed Devices are listet in the Devices-List even if they are not connected.
- Example: I have installed the drivers for a Lide50 and for a DR-2050c. Now i see a lot of entries because every driver installs more than one device.
- Now i have the 2050c connected to the PC and this is the only Scanner-Device that is listed unter Windows -> Device Manager
- But the VintaSoft DeviceManager is giving me all Scanner-Devices that are possible: The Lide, some Webcams, the 2050c, ...
- If i try to open a Device that is not connected, i will get a Message that the device is not available. - Then i will run in the catch-code where i could handle that.
So: Is there any way to check for a Device being connected or not without getting any Windows-Messages/Dialogs?
My goal is: Only show devices that are really working, only devices that i could ".Open()" without error.
Edit: Oh, and i need this, because i like to Open() the Device to check if Duplex is available or not (I need this to offer this setting or to hide it from the user)
Thanks a lot