Moo Posted May 16, 2007 Posted May 16, 2007 Hey, I'm trying to write a batch file that will switch my realmlist for wow to easily allow me to switch between a private wow server and the public one, however, I can't get it to work... Here it is so far: @echo off dir "C:Program FilesWorld of Warcraft" if exist realmlist.wtf DEL realmlist.wtf cls choice/c:BMQ /N select lizzard [M]agicstar [Q]uit pause >nul IF errorlevel 3 goto end IF errorlevel 2 goto magicstar IF errorlevel 1 goto blizzard :blizzard copy blizzard.wtf realmlist.wtf goto end :maigcstar copy magicstar.wtf realmlist.wtf goto end :end start launcher.exe exit *note, the [ B ] infront of BLizzard is making the text bold, but there is a [ B ] (without spaces) there. However, apparently choice doesn't work, which confuses me because I've seen references to it on several websites.... Can anybody help me figure out how to do it? Quote
Sparda Posted May 16, 2007 Posted May 16, 2007 Easier alternative is just to write separate scripts and you run which ever it is that you require at that time? Quote
Moo Posted May 16, 2007 Author Posted May 16, 2007 well, I wanted it to be easily accessible, (just to change the shortcut on my computer to run the command again...) is there any way to do it? Quote
Sparda Posted May 16, 2007 Posted May 16, 2007 well, I wanted it to be easily accessible, (just to change the shortcut on my computer to run the command again...) May be I'm stupid (which I probably am, though hilarity some times ensues through my weired stupidity), but having two short cuts on the desktop sounds more accessible then having to modify one short cut every other click. It's the easiest way I think.: script0: @echo off dir "C:Program FilesWorld of Warcraft" if exist realmlist.wtf DEL realmlist.wtf copy blizzard.wtf realmlist.wtf start launcher.exe exit script1: @echo off dir "C:Program FilesWorld of Warcraft" if exist realmlist.wtf DEL realmlist.wtf copy magicstar.wtf realmlist.wtf start launcher.exe exit Quote
Moo Posted May 16, 2007 Author Posted May 16, 2007 This is true, I suppose, but I like to keep my desktop uncluttered, and I was hoping to be able to do it all from the shortcut. Quote
GonZor Posted May 16, 2007 Posted May 16, 2007 If I were doing this i would replace this... choice/c:BMQ /N select [B] lizzard [M]agicstar [Q]uit pause >nul IF errorlevel 3 goto end IF errorlevel 2 goto magicstar IF errorlevel 1 goto blizzard With this... ECHO 1. Blizzard ECHO 2. Magicstar ECHO 3. Quit SET /p choice="Please Select an Option: " IF '%choice%' == '1' GOTO blizzard IF '%choice%' == '2' GOTO magicstar IF '%choice%' == '3' GOTO end Although I do agree with sparda if you have room for two files on your desktop go with sparda's idea Quote
Moo Posted May 16, 2007 Author Posted May 16, 2007 If I were doing this i would replace this... choice/c:BMQ /N select [B] lizzard [M]agicstar [Q]uit pause >nul IF errorlevel 3 goto end IF errorlevel 2 goto magicstar IF errorlevel 1 goto blizzard With this... ECHO 1. Blizzard ECHO 2. Magicstar ECHO 3. Quit SET /p choice="Please Select an Option: " IF '%choice%' == '1' GOTO blizzard IF '%choice%' == '2' GOTO magicstar IF '%choice%' == '3' GOTO end Although I do agree with sparda if you have room for two files on your desktop go with sparda's idea This works like a charm! Thanks! Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.