Link to home
Start Free TrialLog in
Avatar of avirocks12345
avirocks12345

asked on

WIA driving me a little crazy. Can only transfer one file from common dialog box with Access/VBA

Lately I've been looking for a good solution for integrating Camera Stills into an Access 2007 database. Right now I'm settling on taking pictures with a Digital Camera and grabbing them with WIA. The problem I'm having is that I can only get the WIA generated common dialog box to give my one picture at a time, rather than allowing me to grab multiple pictures at once.

This is the common dialog box that I'm looking for, note that it says to grab more than one image hold shift or ctrl:
 User generated image
This is what mine looks like, it only allows one picture at a time:
 User generated image
I'm using windows 7 64 bit and access 2007, but tested the code on windows XP 32bit just to make sure. Also same result with 2 different cameras

I've tried this code:
    Dim Commondialog1 As WIA.CommonDialog
    Dim wiadevice As Object
    Dim wiadevice1 As Object
    Set Commondialog1 = New CommonDialog
    Set wiadevice = Commondialog1.ShowSelectDevice
    Set wiadevice1 = Commondialog1.ShowSelectItems(wiadevice)

Open in new window


And this code:
    Dim imfile As WIA.ImageFile
    Dim Commondialog1 As WIA.CommonDialog    
    Set Commondialog1 = New CommonDialog
    Set imfile = Commondialog1.ShowAcquireImage

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Nick67
Nick67
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of avirocks12345
avirocks12345

ASKER

Oh! That was sooo simple, Thank you very much Nick, I can't believe I missed that!