Command Line Arguments

Hi. New to Xojo and I’m trying to pass an argument to the program I’m writing, so I can decide one of two things that the program will do. Is there a way?

For desktop applications: http://documentation.xojo.com/index.php/System.CommandLine

For Console Applications: http://documentation.xojo.com/index.php/ConsoleApplication.Run
Use the Args() array.

Thanks
Is there a way that I can pass this argument to the run command when I test the program?

https://forum.xojo.com/3018-controlling-another-application

[quote=21438:@Andre Forest]Thanks
Is there a way that I can pass this argument to the run command when I test the program?[/quote]

There should be run with under the build settings (shared).
there yu can put your commandline parameters wich will be added if it’s being run from the ide.

As I said before, I am new to Xojo. So, how do I get to Build Settings?

Found the Build Settings. Thank you

Can this be done in a Web Program?

I think so but am not sure on Web Edition

Yes, it works the same.

For debugging, you can pass the arguments in the shared build settings “Command Line arguments”.

But on the web, you have also the notion of URL parameter. See URLParameter at http://documentation.xojo.com/index.php/Websession