[Gtk-sharp-list] Embedded forms

Raúl Moratalla raul.moratalla@ono.com
Fri, 16 Jul 2004 14:34:29 +0200


Néstor Salceda escribió:

>On jue, 2004-07-15 at 23:46 +0200, Raúl Moratalla wrote:
>  
>
>>Hi everybody,
>>I am a newbie programmer with MONO and GTK# and I would like to know if 
>>should be possible to do the following:
>>I have designed 3 forms with Glade, one of them is the master. I would 
>>like to load form2 at the bottom of the master form (as it was embedded) 
>>when I click on a button, and if I click in another button I want to 
>>load the form3 (and hide form2) embedded at the bottom of the master form.
>>Should it be possible? Could anyone explain to me how to do this?
>>    
>>
>
>	Yes, it's possible.  I don't know if this mode is the best to do this,
>but it works.
>
>You use an object Glade.XML for each form.  For example:
>
>//Shows the form1
>Glade.XML gxml1 = new Glade.XML ("file.xml","form1",null);
>gxml1.Autoconnect (this);
>
>//Show form2
>Glade.XML gxml2 = new Glade.XML ("file.xml","form2",null);
>gxml2.Autoconnect (this);
>
>//Show form3
>Glade.XML gxml3 = new Glade.XML ("file.xml","form3",null);
>gxml3.Autoconnect (this);
>
>file.xml is the same file; and formX the form which you want to show.
>
>  
>
>>Thanks in advance,
>>
>>Raúl
>>    
>>
Hi Néstor, I tried the same code before send my e-mail but it only loads 
each form, and it don't embbed one form inside another :(
I will do it as Fredrik has explained, thanks for your help :)

Best regards,
Raúl