VintaSoft Twain .NET SDK Discussions

Questions, comments and suggestions concerning VintaSoft Twain .NET SDK.

Board index < VintaSoft Twain < VintaSoft Twain .NET SDK Discussions

We are migrating to new forums engine, no new registration or posting currently available. TIA for your patience.

Detecting if a scanner is connected



Detecting if a scanner is connected

Post by jchristian »

Hi Alex,

Is there a way through the Vintasoft Twain SDK to detect if a scanner is connected or not?
Using the current devicemanager class, whether or not I have a scanner connected, it always shows a TWAIN device available.
I would like to disable some UI elements if there isn't a scanner connected, so the end user is aware of it.
So far I am not having much luck in getting this to work.

Thank You!


Re: Detecting if a scanner is connected

Post by Alex »

Hi,

The DeviceManager class provides information about installed TWAIN drivers. Next, you need try to open the device - device is connected and ready to use if you can open the device, device is not connected or not ready for use if you cannot open the device.

Best regards, Alexander


Re: Detecting if a scanner is connected

Post by Echtelion »

Hi,

I have a similar problem, with Canon devices reporting in .Devices collection while disconnected.

The problem is that Device.Open() show a messagebox when not connected, even with ShowUI and ShowIndicators set to false.
That's a problem when I want to enumerate devices and select the one actually connected : lots of useless messagebox.

You can easily reproduce the issue by installing this driver, even without the device.
http://www.canon.fr/support/consumer_pr ... pe=drivers

Is it something you can fix on your side ?
Thanks.


Re: Detecting if a scanner is connected

Post by Alex »

Hi,

The DeviceManager class provides information about installed TWAIN drivers. Next, you need try to open the device - device is connected and ready to use if you can open the device, device is not connected or not ready for use if you cannot open the device.

Unfortunately, most TWAIN drivers show dialog with error message if scanner is not connected or online. Message dialog depends from TWAIN driver developer and in most cases cannot be disabled.

Best regards, Alexander


Page 1 from 1: 1