Sign in to follow this  
Followers 0
MarioX

How to compile/build command mode only program (without GUI)

7 posts in this topic

It's probably a dumb question, but how to compile/build AutiIt program for running it from a cmd shell, like the old pkzip.exe or rar.exe for example, that run without graphics GUI and output messages in text mode only ?

Thanks for any advice

Share this post


Link to post
Share on other sites



In Helpfile under contents section

AutoIt -> Using AutoIt -> Compiling Scripts. Look at Method 3 - The Command Line.

Share this post


Link to post
Share on other sites

Thanks for your help.

Mario

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

Ops, I had read the suggested help file but it's not what I mean, I probably wrote in confused way...

I wonder if using AutoIt is possible made "command mode" program, like fdisk or format for example.

Thanks again for any clarification.

Edited by MarioX

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

Thanks for any advice

How about looking at "$cmdline" in the help file. This lets you take parameters on the command line. I always use it as follows, so that if the user forgets to put in the command line parameter it pops open an inputbox. However, you could put in an error message instead that just shows the proper useage of your exe:

if $CmdLine[0] = "" Then
    $var = InputBox("Enter parameter", "Please enter a parameter","default")
Else
    $var = $CmdLine[1]
EndIf

Also, be sure to read up on "@sw_hide" to hide any dos boxes that are launched when you use "run". As for writing to the command line from your program, I don't believe you can do that, but will have to rely on "msgbox" or "splashtext" or "tooltip" for output.

Edited by jefhal

...by the way, it's pronounced: "JIF"... Bob Berry --- inventor of the GIF format

Share this post


Link to post
Share on other sites

Command line parameters handling could be a useful thing to know, thanks for the information.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0