[Gambas-user] Arrays again

Dag-Jarle Johansen dag.jarle.johansen at ...626...
Tue Sep 13 00:12:02 CEST 2011


danke,

the info about the DEBUG was new to me, but should not have any influence on
the problem as is. I will play a little around with it, and if it does not
work, come back to you experts :-)

regards
Dag-Jarle


2011/9/12 tobias <tobiasboe1 at ...20...>

> On 12.09.2011 22:20, Dag-Jarle Johansen wrote:
> > Hi,
> >
> > I am feeling a little stupid, but I just can't make this running:
> >
> > Public xxx As Control (or Public xxx As Object)
> >
> > public sub ChangeControls()
> >          DIM I as integer
> >          For I = 0 To mTrans.LoginCount - 1
> >              For Each xxx In Me.Children
> >                  Debug xxx.Name
> >                  If xxx.Name = mTrans.TNLoginName[I] Then
> >                      xxx.Text=mTrans.TNLogin[I]
> >                  Endif
> >              Next
> >          Next
> >
> > TNLoginName[] and TNLogin[] are predefined arrays, and seem to work.
> > In the Debug xxx.Name nothing happens, and the control XXX can not have a
> > text, though Tooltip is possible,
> > If I define xxx as Object I can have a Text, but not a Tooltip.
> >
> > At the moment nothing really works, and as I am a extrem database-fan, I
> > would like to manipulate every given object as far as possible.
> > I am pretty sure I have misunderstood something here, so please help me.
> >
> > Thanks in advance, regards
> > Dag-Jarle
> the debug instruction only works if compiled with debugging information
> (as the documentation states), i hope, this is the case?
> why don't use Print or if it has to be stderr, Error?
> however, things like this (iterating through container children and
> changing attributes) normally work for me, if the strings in the array
> match the names of the controls? i quite can't imagine why there is a
> difference between using xxx As Control and As Object but i never tried
> using As Control...
>
>
> ------------------------------------------------------------------------------
> Doing More with Less: The Next Generation Virtual Desktop
> What are the key obstacles that have prevented many mid-market businesses
> from deploying virtual desktops?   How do next-generation virtual desktops
> provide companies an easier-to-deploy, easier-to-manage and more affordable
> virtual desktop model.http://www.accelacomm.com/jaw/sfnl/114/51426474/
> _______________________________________________
> 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