I need to know if you can put wildcards in strings. For example, I want to make an error message appear if the command has the right prefix, but an invalid extension.
Here is where I want the wildcard to be inserted:
Code: Select all
set var1=iexplore
set var2=notepad
set var3=chrome
set /p command=^>
if /I "%command%"=="start %var1%" start %var1%
if /I "%command%"=="start %var2%" start %var2%
if /I "%command%"=="start %var3%" start %var3%
if /I "%command%"=="start [WILDCARD]" echo Unknown Application!