UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
 
   Reply to this topicStart new topic
> Capture Webcam Image - Win10 & Access 2016/365, Access 2016    
 
   
duffy132
post Apr 5 2020, 04:28 PM
Post#1



Posts: 10
Joined: 8-October 19



I have a time tracking project where I want to capture an image from a webcam when an employee scans in. Want to trigger the capture after scan is read.

After scouring the web I can only find VBA solutions using WIA. However it appears WIA does not play well with WIN10 and Access 2016/365.

Loaded the dll, registered it, and selected the reference library. I took some bare bones code from the web and also has a routine to just identify your WIA cams. When I run there are no errors only a dialogue box from the code that returns a message that no WIA devices were found.

I have both an integrated camera on my Lenovo PC and a USB Logitech C910.

Any assistance is greatly appreciated.
Go to the top of the page
 
DanielPineault
post Apr 5 2020, 06:27 PM
Post#2


UtterAccess VIP
Posts: 7,338
Joined: 30-June 11



WIA no longer works, sadly. You need to look into capCreateCaptureWindow and SendMessage APIs. You'll also need to get into adjusting based on the applied DPI so the images aren't distorted.

Others have recommended https://access.bukrek.net/ in the past (but I've never used it so I can't endorse it).

--------------------
Daniel Pineault (2010-2019 Microsoft MVP, UA VIP, EE Distinguished Expert 2018)
Professional Help: https://www.cardaconsultants.com
Free MS Access Code, Tips, Tricks and Samples: https://www.devhut.net

* Design should never say "Look at me". It should always say "Look at this". -- David Craib
* A user interface is like a joke, if you have to explain it, it's not that good! -- Martin LeBlanc


All code samples, demonstration databases, links,... are provided 'AS IS' and are to be used at your own risk! Take the necessary steps to check, validate ...(you are responsible for your choices and actions)
Go to the top of the page
 
Gustav
post Apr 6 2020, 02:57 AM
Post#3


UtterAccess VIP
Posts: 2,239
Joined: 21-February 07
From: Copenhagen


Perhaps you can use TWAIN. Browse to paragraph 8.2 here:

ctXImage - TWAIN

The control isn't free but fairly priced. I have used it for image manipulation with excellent results, and the support is first class.

--------------------
Microsoft Office 365 (Access) MVP 2017 ->
Go to the top of the page
 
shadow
post Apr 6 2020, 10:37 AM
Post#4



Posts: 307
Joined: 19-April 04
From: Toronto


QUOTE
WIA no longer works, sadly



Thanks for the info. Every time I see someone post some new code or a demo claiming to be able to capture from a webcam, I try it out and get the same result as duffy. I didn't realize that it's now another addition to the list of things that "no longer work"

Go to the top of the page
 
duffy132
post Apr 12 2020, 07:23 PM
Post#5



Posts: 10
Joined: 8-October 19



I found this which walks through modifying VB code to Access VBA. I was able to get it to work on a WIN10 machine with Access 2016.

While it ran I did run into an issue where if you start cam and stop cam. Then you start cam again it doesn't bring up image again. Need to close out app and relaunch. Not fluent enough message calls to troubleshoot.

I also safely downloaded the authors db from link in article at end.



https://stackoverflow.com/questions/5675796...oft-access-form

Go to the top of the page
 
duffy132
post Apr 14 2020, 01:32 PM
Post#6



Posts: 10
Joined: 8-October 19



Not being very strong with SendMessages and API's, I found this neat little executable CommandCam. Kudos to Ted Burke. https://batchloaf.wordpress.com/commandcam/

Not end all solution but in certain situations it can be useful in Access/Excel. I played around with it in Access and will use in a Time Clock app I'm working on. When employee scans in with badge it will snap photo.

I attached my sandbox Access app. Extract both Access and CommandCam exe into same folder. Then run app. Have fun.
Attached File(s)
Attached File  CommandCam.zip ( 68.82K )Number of downloads: 7
 
Go to the top of the page
 


Custom Search


RSSSearch   Top   Lo-Fi    27th May 2020 - 08:33 AM