R: [Gambas-user] How to change the name of an object on the fly.. ...?

Benoit Minisini gambas at ...1...
Tue Mar 29 15:55:50 CEST 2005


On Tuesday 29 March 2005 15:42, Premoli, Roberto wrote:
> >In other words.
> >I want to replace the "number" by the content of a var, this way I
>
> could >write a loop function to update all my text box. I have no Idea
> of how to >do that.
>
> >Would be something like use %s,index in c++. :) but how to do that in
> >gambas?
> >I heard that in MS VB you can index the text boxes and then use the
>
> index >to do what I want. Is this resource avaliable in gambas?
>
> >Thanks in Advance
> >Andre Silveira
>
> As far as i know, this feature DOESNT exist in GAMBAS :-(
> I regret so much this leak, because to index the objects is a SMART way
> to work when there are many object to manage: more, it is elegant to use
> a for-next cicle for a quick work on an array of objects. I hope this
> feature will be implemented as soon as possible.
>
> Roberto
>

I won't implement this "feature" to prevent you from writing bad code. Gambas 
is not Visual Basic :-)

If you have many textboxes for doing the same thing, then you must not create 
them in the IDE, but dynamically in your code, and assign them to an array of 
object. 

You will find examples of that in this mailing-list If I remember...

Regards,

-- 
Benoit Minisini
mailto:gambas at ...1...




More information about the User mailing list