peskywinnets
Registered User.
- Local time
- Today, 10:37
- Joined
- Feb 4, 2014
- Messages
- 576
So I'm using hotkeys to call macros - it all works well, but occasionally, I want to exit from a specific macro (scanning barcodes), so I've put a simple if statement, along the lines of....
...the problem (I think!) is that the 'End' only exits the VBA, which still takes me back to the original macro ...which then barfs....so my question is how can I exit VBA code & the parent macros instantly (without having to click on further onscreen messages)
thanks in anticipation.
Code:
UserScannedBarcode = InputBox("Now Scan the PRODUCT Barcode(s)")
If UserScannedBarcode = "e" Or UserScannedBarcode = "E" Then
DoCmd.Close acQuery, "ScanBarcodes"
[B]End[/B]
End If
...the problem (I think!) is that the 'End' only exits the VBA, which still takes me back to the original macro ...which then barfs....so my question is how can I exit VBA code & the parent macros instantly (without having to click on further onscreen messages)
thanks in anticipation.