Jump to content

Recommended Posts

Posted

I can't find anything on this, but maybe I'm a blind bastard...

Is there a way to send switchs to your auto it program to do cerntain things.

So if you did. "myprog.exe /?" You would get a help message box?

Or something like "myprog.exe /input"

If $prog_switch = "/input" then
;Do this
Else
;Do this
Endif

Thanks

Posted (edited)

Thanks for the quick response!

My program is called "Member_test.exe"

With you code, I would shell this command "Member_test.exe /?" to get the messagebox?

If so, it's not working for me.

Should do.. this is from one I used to copy one folder to another sending the 2 directories from the command line.

If $cmdline[0] = 2 Then
    $DirSearch = $cmdline[1]
    $Destination = $cmdline[2]
    StartCopy ($DirSearch,$Destination)
Else
    MsgBox(0,'Invalid # of parameters!',$cmdline[0]&' is an Invalid number of parameters.')
    Exit
EndIf

so i would type DirCopy.exe D:\start D:\End

this would send the 2 folder names to the function startcopy()

I think I had issues when my program name was too long, try renaming your program to 8chr length name

Edited by ChrisL

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...