Gambas/Useful Modules

Back to Gambas

Useful Modules edit

All useful modules are grouped in components.

Try to master the Settings component at the beginning!

In project properties, in components, activate the gb.settings!

You can use it like this (for example, in a Form named FMain with a Label named Label1) :

' Gambas class file

' FMain

Private $counter As Integer = 0

Public Sub Form_MouseUp()

  Settings.Reload
  Message.Info(Settings["My/Ref", "default"])

End

Public Sub Label1_MouseDown()

  Inc $counter
  Settings["My/Ref"] = CStr($counter)
  Settings.Save

End