How do I reset a combobox to a specific item in the items collection?

I have a form that is used to gather search criteria.  One of the controls is a button to clear all the fields to start a new search, another control is a combo box that is populated from the items collection of "NO", "YES", "MAYBE", "DON'T KNOW".  Because 95% of the time the answer is "NO", the user wants that to be the default value and it will only be changed rarely.   Here is what I have so far:

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
         ClearScreen(Me)
         Me.ComboBox.Text = "No"
     End Sub

    Public Sub ClearScreen(ByVal FormName As Form)
        Dim ctl As Control
        For Each ctl In FormName.Controls()
                If ctl.Tag Like "Init*" Then
                    ctl.ResetText()
                End If
        Next
     End Sub

This works great on form1_load.  My problem is when the user clicks the "Clear" button and I execute the same code I do on form1_load, the combobox is now empty.  How do I get it to display the "NO" again?
cswebdevAsked:
Who is Participating?
 
gdexterCommented:
Put the above code at the end of the ClearScreen method
0
 
gdexterCommented:

  As long as you are not clearing the combo box you can do this:

  Me.ComboBox.SelectedIndex = Me.ComboBox.FindString("NO")
0
 
cswebdevAuthor Commented:
I knew it had to be something simple I was missing!  Thank you very much.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.