Subject: [Gtk-sharp-list] Gtk.Combo Entry.Activated pb

th3 m0nq th3m0nq at
Sun Jul 17 13:33:35 EDT 2005

> I try to use a combox, and i a System.NullReferenceException when try to set a event on the Combo.Entry.Activated.
> Does anyone got an idea?
> ConnectionCombo = new Combo ();
> string[] pop = {"Foo", "Bar"};
> ConnectionCombo.PopdownStrings = pop;
>  //  ConnectionCombo.DisableActivate ();
>  //  This Crash
> ConnectionCombo.Entry.Activated += new EventHandler (OnConnectionComboActivated);
> hbox.PackStart (XboxsConnectionCombo, false, false, 10);

I would assume you didn't properly initialize your ConnectionCombo.
Null references occur when you forget to initialize a reference, then
try to access it as though you were referencing an actual object.
Hope that helps.  Sorry I didn't reply properly the first time.

Adrian V.

More information about the Gtk-sharp-list mailing list