Home > Software engineering >  Vb.net button to maintain focus
Vb.net button to maintain focus

Time:10-14

The code is as follows:
Private Sub btn1_Click (ByVal sender As System. Object, ByVal e the As System. EventArgs) Handles btn1. Click
'button active set, prevent combo
Btn1. Enabled=False
Btn2. Enabled=False
Btn3. Enabled=False
.

Btn1. Enabled=True
Btn2. Enabled=True
Btn3. Enabled=True
End Sub

Among them, the btn1. TabIndex=0, btn1 TabIndex=1, btn1. TabIndex=2,
Problems: 1. Can effectively prevent the combo 2. Click the btn1, focus can remain on btn1,
(now button is inactive, the focus will move on to the next button btn2)
Is there a great god could help fix,
  • Related