• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Deselect a Lixtbox when textbox receives focus

Status
Not open for further replies.

S P P

Member
Deselect a Lixtbox when textbox receives focus

I click on the New button and the textbox receives focus.

I need the textbox to deselect the listbox when it receives focus.
 

Attachments

  • Deselect a Lixtbox when textbox receives focus.xlsm
    22.6 KB · Views: 6
I already tried it doesn't work

Private Sub LBx1_Change()
TBx1 = LBx1.List(LBx1.ListIndex, 0)
End Sub
 
I got it like this
Private Sub LBx1_Click()
For i = 0 To LBx1.ListCount - 1
If LBx1.Selected(i) Then
TBx1 = LBx1.Value
Exit For
End If
Next
End Sub


Excludes

Private Sub LBx1_Change()
TBx1 = LBx1.List(LBx1.ListIndex, 0)
End Sub
 
Status
Not open for further replies.
Back
Top