Listbox inside a Gridview gives a nullpointer exception

G

Guest

I have a gridview, and a listbox which has a different datasource. The
listbox contains distinct types of contacts, whereas the gridview will get
populated upon contact type selection.

The data is displayed but when on submission of the contact type from the
list box i get a null reference exception.

I already tried to trap using SelectedIndex -1 but that does not work..

Any pointers.

Thanks in advance
 
A

Alexey Smirnov

I have a gridview, and a listbox which has a different datasource. The
listbox contains distinct types of contacts, whereas the gridview will get
populated upon contact type selection.

The data is displayed but when on submission of the contact type from the
list box i get a null reference exception.

I already tried to trap using SelectedIndex -1 but that does not work..

Any pointers.

Thanks in advance

Please send a piece of code where you get the exception.
Thanks!
 

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

Top