[Gambas-user] control groups

Stephen Bungay sbungay at ...981...
Tue Mar 4 16:30:33 CET 2008


Stefano Palmeri wrote:
> Alle 13:08, martedì 4 marzo 2008, Kari Laine ha scritto:
>   
>> Stefano Palmeri kirjoitti:
>>     
>>> Alle 10:44, martedì 4 marzo 2008, Kari Laine ha scritto:
>>>
>>> DIM hControl AS Control
>>>
>>> FOR EACH hcontrol IN ME.Children
>>>
>>>     IF object.Type(hControl) = "TextBox" THEN
>>>       PRINT hcontrol.name
>>>     ENDIF
>>>
>>> NEXT
>>>
>>> Stefano
>>>       
>> Hi Stefano,
>>
>> the code you sended me does not test for the Controls Group. So is it
>> possible to use for each syntax for all the controls in the group?
>>
>> Best Regards
>> Kari
>>
>>     
>
> Sorry, I really don't know if it's possible to enumerate all controls of a 
> group with "FOR EACH". Probably, you have to create an array
> of objects of that group. But I'm not sure. 
> Object.GetProperty(hcontrol, "Group") doesn't work, so I don't know...
> Wait for a more more experienced user than me :-)
>
> Ciao,
>
> Stefano 
>   
I think you are correct on this Stefano.
I was reading this thread and recalled that there are no control groups 
in gambas... went to the old "VB has it GAMBAS does not" page and found 
this...

"There's no direct Gambas equivalent to the Index property of VB form 
controls. You can easily create arrays of controls, but you have to do 
it in code. There's currently no way to do it graphically. Thus, when 
you copy a control and paste it back on the form it came from, rather 
than prompting you to create a control array it automatically renames 
the copied control to an appropriate name."

Steve.
>  
>
>
>   
>> -------------------------------------------------------------------------
>> This SF.net email is sponsored by: Microsoft
>> Defy all challenges. Microsoft(R) Visual Studio 2008.
>> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
>> _______________________________________________
>> Gambas-user mailing list
>> Gambas-user at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/gambas-user
>>     
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user
>
>   





More information about the User mailing list