Will it be possibile in a future version to use switches together with a created EXE, that, lets say points to two different bat-files? If using EXE without slash bat1 would be executed and if together with /? then bat2 would be executed.
This is a great app. // Peter
EXE-files with switches - Possibile or in the future
-
- Site Admin
- Posts: 307
- Joined: Fri Feb 13, 2004 5:55 pm
-
- Posts: 10
- Joined: Tue Feb 22, 2005 8:05 pm
I've not tried, but does compiled batch files support switches (so %1= whatever after the exe? ) I only have the trial but it works for me. Example code would be:
Or an even more optamized version:
Code: Select all
@echo off
:start
if "%1" == "" (
goto one
)
if "%1" == "/?" (
goto two
)
:one
call bat1.bat
goto eof
:two
call bat2.bat
goto eof
:eof
cls
Code: Select all
@echo off
:start
if "%1" == "/?" (
goto two
) else (
goto one
)
:one
call bat1.bat
goto eof
:two
call bat2.bat
goto eof
:eof
cls
-
- Site Admin
- Posts: 307
- Joined: Fri Feb 13, 2004 5:55 pm