Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
F5 getting the wrong inkey() value
Message
From
21/03/2010 17:22:25
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Title:
F5 getting the wrong inkey() value
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Miscellaneous
Thread ID:
01455965
Message ID:
01455965
Views:
189
Hi All:

In the thisform.keypress(), I have the following code (I have keypreview set to .t.):
LPARAMETERS nKeyCode, nShiftAltCtrl

LOCAL tnKey
tnKey = LASTKEY()

SUSPEND

DO CASE
CASE tnKey = -4   &&F5
	THISFORM.cmdValidate.CLICK()
CASE tnKey = -5   &&F6
	THISFORM.cmdManual.CLICK()
CASE tnKey = -6   &&F7
	THISFORM.cmdCancel.CLICK()
ENDCASE
When I press F5, both the value of tnkey and nLastkey is 42! What gives?

Thanks,

Yossi
Next
Reply
Map
View

Click here to load this message in the networking platform