[Gambas-user] Little editor "feature" in Gambas2
Benoît Minisini
gambas at ...1...
Sun Jan 16 17:39:21 CET 2011
> Am 11.01.2011 18:42, schrieb Benoît Minisini:
> >> Moin,
> >>
> >> Just found this one, don't know if it's been removed in Gambas3. When I
> >> define several arrays of strings on one line within a SUB, later the
> >> names are recognized. Example:
> >>
> >> DIM sMyStrings1, sMyStrings2 AS NEW String[]
> >>
> >> Then type
> >>
> >> sMyStrings1.
> >>
> >> and the list with "Add, Bounds, Clear..." will appear.
> >>
> >> However, if I define the arrays outside the SUBs for public use, they
> >> will be recognized only if defined solely one by one on a separate line
> >> each, i. e.
> >>
> >> PUBLIC sMyStrings1, sMyStrings2 AS NEW String[]
> >>
> >> then within a SUB type
> >>
> >> sMyStrings1.
> >>
> >> and nothing happens, but if I do
> >>
> >> PUBLIC sMyStrings1 AS NEW String[]
> >> PUBLIC sMyStrings2 AS NEW String[]
> >>
> >> they are recognized.
> >>
> >> Or am I doing something false here the interpreter will understand
> >> wrong?
> >>
> >> Regards
> >>
> >> Rolf
> >
> > I'm afraid it was never implemented, both in Gambas 2 and Gambas 3!
>
> Ok :-) At least, it's not my mistake...
>
Sorry, I told rubbish.
Declaring several variables on the same line is only allowed with the DIM
statement. Each public or private global variable must be alone on its line.
If you try to compile "PUBLIC sMyStrings1, sMyStrings2 AS NEW String[]", you
will get an error.
Regards,
--
Benoît Minisini
More information about the User
mailing list