Was not able to do this personally in a sheet, just on a form
Private Sub workbook_KeyPress(ByVal KeyAscii As _
MSForms.ReturnInteger)
MsgBox KeyAscii
'To handle keyboard combinations (using SHIFT,
'CONTROL, OPTION, COMMAND, and another key),
'or TAB or ENTER, use the KeyDown or KeyUp event.
End Sub
--
-John
Please rate when your question is answered to help us and others know what
is helpful.
"Jim" wrote:
> I would like to display the ascii code of a key after it is pressed.
> Presumably a MsgBox would suffice - Can some point me to a piece of suitable
> code
>
> Regards & TIA
>
>
>
|