[MonoDevelop] Running Mono with Glade ..... ERROR
Paulo Aboim Pinto
esqueleto@tusofona.com
Wed, 14 Apr 2004 03:42:13 +0100
--=-ujc6+AYQzI3KxkgkI8/Q
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable
Hello
I've notice this error but no one answer me.
I'm trying to use Glade to make a GUI interface for my Mono
Client/Server application.
If any one have a better way... please ... tell me.
I build my GUI interface, and just that i can show the form, but, when i
assing a Event (signal) to any of the object i get this error when o
run.
# mono GnomeSharpProject.exe
=
=20
Unhandled Exception: System.NullReferenceException: A null value was
found where an object instance was required
in (unmanaged) (wrapper managed-to-native)
.SignalConnector:glade_xml_signal_autoconnect_full
(intptr,Glade.XML/SignalConnector/RawXMLConnectFunc,intptr)
in <0x00004> (wrapper managed-to-native)
.SignalConnector:glade_xml_signal_autoconnect_full
(intptr,Glade.XML/SignalConnector/RawXMLConnectFunc,intptr)
in <0x0006e> .SignalConnector:Autoconnect ()
in <0x00052> Glade.XML:Autoconnect (object)
in <0x00066> GladeSamples.GladeTest:.ctor (string[])
in <0x00024> GladeSamples.GladeTest:Main (string[])
This form goes well when i use Python, and for that i think that the
problem is with the definitition of the Glade GUI in C# Mono.
This is the source code that i run:
namespace GladeSamples {
using System;
=
=
=20
using Gtk;
using Glade;
using GtkSharp;
=
=
=20
public class GladeTest
{
public static void Main (string[] args)
{
new GladeTest(args);
}
=
=
=20
public GladeTest (string[] args)
{
Application.Init();
Glade.XML gxml =3D new Glade.XML ("project1.glade",
"window1", null);
=
=
=20
gxml.Autoconnect (this);
try
{
Application.Run();
}
catch (Exception ex)
{
Console.WriteLine ("Erro in main \n\n{0}", ex);
}
}
=
=
=20
public void OnWindowClose (object o, DeleteEventArgs
args)
{
Application.Quit ();
args.RetVal =3D true;
}
=
=
=20
=
=
=20
=
=
=20
public void OnButtonClicked (System.Object obj,
EventArgs e)
{
Console.WriteLine ("Button 1 clicked");
}
=
=
=20
}
}
=20
please help
tkx in advance
--=20
Paulo Aboim Pinto
Odivelas - Portugal
--=-ujc6+AYQzI3KxkgkI8/Q
Content-Type: application/pgp-signature; name=signature.asc
Content-Description: This is a digitally signed message part
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)
iD8DBQBAfKUER5pQJCqilfURAtJxAJ9Ake9qH2nwaehZA1S7688lFBPosACaA6jc
hPT+H8pcBH5wkPpAUw3Wuc4=
=evzs
-----END PGP SIGNATURE-----
--=-ujc6+AYQzI3KxkgkI8/Q--