Re: [Gambas-user] Form.Show by name as string of form

2014-04-29 Thread sfdadds
' As the class is specified by name, only exported classes can be instanciated. ' could try dynamic load of a form by name hButton = Object.New("Button", [hParent]) 'has exactly the same effect as: hButton = NEW Button(hParent) -- View this message in context: http://gambas.8142.n7.nabble.com/

Re: [Gambas-user] Form.Show by name as string of form

2014-04-29 Thread Ru Vuott
.43.0.0 Qt4=libQtCore.so.4.8.4 SDL=libSDL-1.2.so.0.11.4 Mar 29/4/14, Jussi Lahtinen ha scritto: Oggetto: Re: [Gambas-user] Form.Show by name as string of form A: "mailing list for gambas users" Data: Martedì 29 Aprile 2014, 14:42

Re: [Gambas-user] Form.Show by name as string of form

2014-04-29 Thread Jussi Lahtinen
> I tried your suggestion, but an error-notice is raised: > >" Not an object " > Where the error comes? I just tested the code and it works on my system. How do you declare the forms? >Object.Call(hMyForms["Form_name_1"], "Show", Null) > This should be same thing than hMyForms["Form_n

Re: [Gambas-user] Form.Show by name as string of form

2014-04-29 Thread Ru Vuott
ot;) hMyForms.Add(Form_name_3,"Form_name_3") Object.Call(hMyForms["Form_name_1"], "Show", Null) Bye vuott ---- Lun 28/4/14, Jussi Lahtinen ha scritto: Oggetto: Re: [Gambas-user] Form.Show by name as string of form A: &

Re: [Gambas-user] Form.Show by name as string of form

2014-04-28 Thread Jussi Lahtinen
Private hMyForms As New Collection() hMyForms.Add(Form_name_1,"Form_name_1") hMyForms.Add(Form_name_2,"Form_name_2") hMyForms.Add(Form_name_3,"Form_name_3") ... hMyForms["Form_name_1"].Show() Jussi On Mon, Apr 28, 2014 at 10:54 AM, abbat81 wrote: > Hi, > > I have a four forms in my proje

[Gambas-user] Form.Show by name as string of form

2014-04-28 Thread abbat81
Hi, I have a four forms in my project: Form_name_1 Form_name_2 Form_name_3 Form_name_4 Form_name_5 How can I show a form by name of a form by string. Public Sub Button1_Click() Dim Form_name As String = "Form_name_2" Form_name.Show End -- View this message in context: http://gambas