title: VB Radio button and Combo Box Flash
body: <p>I have written a small piece of code to change the display member of my combo box when a radio button is selected. The only problem I'm having is that when I switch between the radio buttons the combo box disappears then comes back a second later, is there any way of resolving this problem.</p>
  
  <p>Private Sub SearchOptionChange(sender As Object, e As EventArgs) Handles RBExchange.CheckedChanged, RBPostcode.CheckedChanged</p>
  
  <pre><code>    Dim RB As RadioButton = CType(sender, RadioButton)
      If RB.Name = "RBExchange" AndAlso RB.Checked Then
          ComboBox1.DisplayMember = "Exchange"
          ComboBox1.Text = ""
  
      ElseIf RB.Name = "RBPostcode" AndAlso RB.Checked Then
          ComboBox1.DisplayMember = "Postcode"
          ComboBox1.Text = ""
  
      End If
  
  
  End Sub
  </code></pre>