How to update field after combo Box changes tia sal

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Greets,

I have a question I have combo box that gets a column in a dataset when I change the combo box
the dataset changes and that works well. The problem is the fields on the from that correspond to
the Combo Box don't Change and I get an error " An unhandled exception of type 'System.NullReferenceException' Occurred
in system.data.dll what am I doing wrong.

Code:
Private Sub frmNoTab_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
SqlDataAdapter1.Fill(DataSetElements1, "Elements")
End Sub

Private Sub ComboBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ComboBox1.SelectedIndexChanged
DataSetElements1.Clear()
SqlDataAdapter1.Fill(DataSetElements1, "Elements")
End Sub


TIA
 
Sal,

The combobox is a great control however when you will search the dotnet
newsgroups you see a lot of complaints about not resolved bugs.

Most of those are to pass by disable the selectionchange event. I have at
least one which I was never able to pass and that is a dynmamic binding from
a combobox text area.

Therefore you have in my opinion to tell something more what you are doing.

Cor
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top