|
-
Nov 22nd, 2011, 03:31 PM
#1
Thread Starter
New Member
[RESOLVED] Prevent user from press 'Enter' twice in a few seconds
Hello,
I'm new on this, hope you can help me. I have an application that change the status on a record once user press "enter", but sometimes user gets desperate and hit the key enter multiple times, when screen comes back, shows multiple records as processed.
Any idea how can I accept the enter code, process and if I get another 'enter' show a message saying "You already press enter, wait for process to finish!"
Thanks for your help
Here's part of my code:
Private Sub KeyDown(KeyCode As Integer)
'If the Initialize prompt is up, then do nothing
If picWait.Visible = True Then Exit Sub
If SeqCK = 1 Then Exit Sub
If KeyCode = 96 Then 'Key is 0 then go decrement by one
Log " O Key - Moving Backward"
BK
ElseIf KeyCode = 13 Then 'Key is Enter then increment by one
Log " ENTER Key - Moving Forward"
'BM
MoveForward
ElseIf KeyCode = vbKeyAdd Then 'Key is Plus / Add key then increment by one
Log " * Key - Moves rebuilds Forward"
'BM
MoveForwardRebuilds
End If
End Sub
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|