[Gambas-user] Object.Attach Problem
R. Stormo
rohnny at ...1248...
Sat Sep 16 08:23:20 CEST 2006
Benoit Minisini wrote:
>
> On Monday 11 September 2006 19:33, R. Stormo wrote:
>> I have a prolem with Object.Attach.
>>
>> When this is set Object.Attach(myform, ME, "myform")
>>
>> the form_resize does not work as it should
>>
>> sub form_resize ()
>>
>> Panel1.Width = ME.Width
>> Print "hello"
>>
>> end
>>
>> When the object.attach is set then print hello does work but not
>> pane1.width. When I disable the object.attach
>>
>> the function is working as it should. Is there a sensible answer for
>> this?
>>
>>
>> Regards Rohnny
>> http://forum.stormweb.no
>
> If your event name is "myform", then your event handler must be named
> "myform_resize".
>
> Regards,
>
> --
> Benoit Minisini
>
>
>
That I understand. Ill try to explane it again.
----
Form1 -
Dim f as form
f = new myform
Object.Attach(myform, ME, "myform")
Sub myform_do_calulations()
f.DO_my_routine()
end sub
----
form2 (myform)
sub form_resize()
Panel1.Width = ME.Width
Print "hello"
end sub
What do work in form2 is only print "hello" so it do go into the routine on
the form, but it do not set the panel.width
The reason form the object.attach is that I have other routines that shall
be updated outside the form2 (myform). But at the same time
sub_close , sub_resize should work also.
Regards Rohnny
http://forum.stormweb.no
--
View this message in context: http://www.nabble.com/Object.Attach-Problem-tf2253826.html#a6337039
Sent from the gambas-user forum at Nabble.com.
More information about the User
mailing list