Beta! (now 0.1.5)
Gambas 3 has the nice feature to show you variables that are not used, so you can keep your code clean.
Gambas 2 doesn't have this feature, so "ProbableCause" does it for you:
1. Choose your project with File, Open
2. Push project button to get all the program code files (.module and .class)
3. Scan all files (or select one/some of the files) and press the button to start scanning
You get lists on your screen that get filled with the variables you used, sorted in public, private, and local variables.... read more
When Settings form is opened, connection to Import DB is tested
Everytime I use it, I need something else, so some adjustement:
Split the functions on the screen:
- ping a range (to see what addresses are free)
- ping a host (to check if ip address changes)
Chess Clock with setting for time to play or time to think, display with two clocks, switches on with space, switch player with space or mouse click.
Indicates when player reached 90% of his time.
When time over in running clock, clock turns red and stops.
When clock stopped, shows min and max thinking time, plus average for every player.
Gambas Exercise on the use of a Timer.
Store the readings of all counters: gas, electricity, solar Photovoltaic installation, water and other meters. Compare with previous reading value and calculate the difference immediately. Make new meter with properties as name, description and an image. Choose the meter from a drop-down list with the names or from the picture in a picture-bar. Other applications can do calculations on the data that is stored in MySQL database. (show in dashboards, alarm or react on peak values etc)
Make an array with random sequence of given range of 1 to maxnumbers.
At start the maximum number must be given, e.g. 10.
The array is filled with random numbers out of 1-10, none comes double, and zero is avoided.
By sequentially reading all the numbers from the array, you get "random" order the numbers from the range 1-10
Number of graphic elements ("squares"), eg 10, have to be drawn on screen, so that the available space is filled as good as possible. So that 9 images fills the given surface nicely, but given 11 leaves one square unused.
Can be used for buttons, cardgames, POS, ...
DistributeSquares first guesses and draws on screen: images run somewhat from the screen. An alternative is a second calculation on the results of the first, to correct it slightly; clear and draw again (see buttons), and with recalculate2 the images are spread nicely over the available space.
Filler shows a Form FMain with Arrangement = Fill mode, containing:
HBox1 expand=TRUE in itself containing:
- VBox1 (VSplit1: Panel1, Listbox)
- Frame1: VBox2 (HBox2, HBox3), ListBox2
This projects shows how to create an array of objects. The objects in this example are "Gambas" buttons.
The number of objects is not known in advance; the array is made at runtime;
Test click on the button will show the button's id in the log-window underneath.
Have fun.... read more