[Gambas-devel] Using command line arguments in GUI applications

Tobias Boege taboege at ...176...
Tue Aug 19 21:28:12 CEST 2014

On Tue, 19 Aug 2014, Geoffrey De Belie wrote:
> Hi,
> After reading the documentation at http://gambasdoc.org/help/comp/gb.args/args/has?v3 I'm not sure how to use command line arguments in Gambas. Can you explain it to me?
> 1) Is it possible to pass command line arguments to my GUI application? If so, how?
> 2) How can I define command line arguments (options) like --execute, -e or --replace, -r?

Does the attached project help you?

Note that you call the Gambas interpreter to start your Gambas program. The
interpreter takes arguments of its own so you have to take the canonical
measures (i.e. the sole double dash) to make gbx3 leave your argument to

  $ gbc3 && gbx3 -- --replace ABC

in your project directory will compile and call the program.

Also, you wrote this message to the gambas-devel mailing list which is for
people who contribute to Gambas. To ask Gambas user/usage questions like
yours, there is the gambas-user mailing list (which I'm CC'ing now). You
will likely get an even quicker response there :-)


"There's an old saying: Don't change anything... ever!" -- Mr. Monk
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gui-args-0.0.1.tar.gz
Type: application/octet-stream
Size: 4807 bytes
Desc: not available
URL: <http://lists.gambas-basic.org/pipermail/devel/attachments/20140819/6413d952/attachment.obj>

More information about the Devel mailing list