I want to open IE from a batch file and wait untill it is closed before going to the next line of the batch file. How to do this? BTW iexplore command seems to be not workin
start /wait whatever.exe
The /wait flag will make start wait until the program closes before it returns.
As for iexplore not working, you're right. That's curious... However, you can still invoke it with a full path:
start "" /wait "c:\Program Files\Internet Explorer\iexplore.exe" http://stackoverflow.com
I've updated the second command line to work around some manner of bug in start's command processing. It's weird. However, the proper way to do this is:
start /wait http://address.com