Windows CMD - *.bat file with parametresAvo User Offline 13.05.12 07:21:29 pm Hi, I want to know (if it's possible) how to create *.bat file which can have parametres. I mean when I will use in Windows's cmd: 1mybatfile.bat -action1 it will for example create new folder or when I use: 1mybatfile.bat -action2 it will delete folder, but when I use: 1mybatfile.bat it'll just show some text with command echo ?? Anybody help ??
Re: Windows CMD - *.bat file with parametresFlacko User Offline 13.05.12 07:35:38 pm If I recall correctly, %0 is the bat's path, %1 is the first parameter, %2 the second, and so on... Batch file: 1ECHO %1 Calling it: 1echoit.bat HelloWorld
Re: Windows CMD - *.bat file with parametresAvo User Offline 13.05.12 08:01:39 pm 123cls @echo %1 pause echoit.bat txt shows: 1txt thanks *edit* One more question: will it work when I convert *.bat file to *.exe file with .bat to .exe converter? edited 1×, last 14.05.12 10:16:35 pm