Forum Discussion
bcstss
Jun 01, 2021Copper Contributor
MS Access - looking for help with some 'under the hood' coding.
I have developed a chromebook inventory database. What I would like to do is 'check in' chromebooks that have been returned by using a barcode scanner. I have a table that has the asset tag, oth...
Woldman
Jun 08, 2021Iron Contributor
Hello Gregory,
I could think of a solution with the (VBA) timer-event of the pop-up form that checks if a scan occurred. I would set the timer to fire every x milliseconds and within (the VBA) Form_Timer subroutine I would execute the following 'actions':
1. Check with an If-statement if the asset # is filled (by the barcode scanner).
2. If asset # is filled, run a query with DoCmd.RunSQL to UPDATE the yes/no field and the Checkindate.
3 Empty the asset # field (with something like Me.txtAssetNo = ""); reset the tag-info if needed.
This way the pop-up stays open, waiting for the next scan. And if that happens, the timer-event processes the next scan. No keyboard or mouse action needed.
Hope this helps.
Best regards,
Tieme
I could think of a solution with the (VBA) timer-event of the pop-up form that checks if a scan occurred. I would set the timer to fire every x milliseconds and within (the VBA) Form_Timer subroutine I would execute the following 'actions':
1. Check with an If-statement if the asset # is filled (by the barcode scanner).
2. If asset # is filled, run a query with DoCmd.RunSQL to UPDATE the yes/no field and the Checkindate.
3 Empty the asset # field (with something like Me.txtAssetNo = ""); reset the tag-info if needed.
This way the pop-up stays open, waiting for the next scan. And if that happens, the timer-event processes the next scan. No keyboard or mouse action needed.
Hope this helps.
Best regards,
Tieme