Hi, I'm creating a sample program in VB6. It is consist only of one textbox and one command button. If I'll press the command button it will output "f" on the textbox as stated on my code below. Can you teach me how to make the command button be "pressed" without using images or pictures using only keyboard keys. For example using the cursor key UP, when I press it, the command button will be "pressed" (it should look like it is being pressed also) and when I release the cursor key Up again then the command button will be "unpressed". I hope you understand what I mean. Here's my first code:
Thanks in advance.
Rich (BB code):
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
On Error Resume Next
Select Case KeyCode
Case vbKeyUp
text1.text = "f" 'output "f" on textbox
End Select
End Sub
Private Sub Command1_Click()
text1.text = "f"
End Sub
Last edited: