[Gambas-user] Beware of the restriction on global variables.

Gianluigi bagonergi at gmail.com
Sun Jan 13 15:45:18 CET 2019


Before the new changes in the declaration of local variables, it was
possible, even if I do not understand the reason, to declare a global
variable to use it in this way:

Private hControl As Control

Public Sub Form_Open()

  For Each hControl In Me.Controls
    Print hControl.Name
  Next

End

Now this code is no longer possible.

Regards
Gianluigi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gambas-basic.org/pipermail/user/attachments/20190113/452d4ed5/attachment.html>


More information about the User mailing list