[Gtk-sharp-list] [part 2] Overloaded method fails in Gtk .14

Pablo Fischer pablo@pablo.com.mx
Wed, 03 Dec 2003 16:55:59 -0600


And thanks again!

So, for the next errors I promise to believe what the compiler says.

Thanks!
El mi=E9, 03-12-2003 a las 15:23, Peter Williams escribi=F3:
> Hi Pablo,
>=20
> On Wed, 2003-12-03 at 14:04, Pablo Fischer wrote:
> > What the ***!!, I've also tried with:
> >=20
> > GLib.Value =3D null;
> >=20
> > and compiles.. but when I try to run it, it crashes :).
>=20
> Again, the compiler is always right: you need to initialize your
> GLib.Value. But the GetValue () function can't initialize that variable
> itself; you need to create an non-null but empty GLib.Value, which
> GetValue can then set.
>=20
> 	GLib.Value value =3D new Value ();
> =09
> 	sel.GetSelected (out model, out iter);
> 	model.GetValue (iter, 0, value);
>=20
> You may also be interested in the GetValue (iter, column) function,
> which returns an the Val property of a temporary GLib.Value, making your
> code cleaner:
>=20
> 	sel.GetSelected (out model, out iter);
> 	object value =3D model.GetValue (iter, 0);
>=20
> Peter
--=20
Pablo Fischer Sandoval (pablo [arroba/at] pablo.com.mx)
http://www.pablo.com.mx
http://www.debianmexico.org
GPG FingerTip: 3D49 4CB8 8951 F2CA 8131 AF7C D1B9 1FB9 6B11 810C
Firma URL: http://www.pablo.com.mx/firmagpg.txt