Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My team has just migrated to Win 7. We have a batch file that is no longer working. Here is the line that has a problem.

start "NameOfWindow" /DSomeDirWeWantCWD ..\SomeDir\SomeNameOfAnEXE m

Under Win XP this command does the following. 1. Executes "SomeNameOfAnEXE" located in directory "SomeDir" 2. Sets the Current Working Directory of the executed process to "SomeDirWeWantCWD" 3. Sets the name of the window to "NameOfWindow"

Under Win 7 step number 3 is not working. The window title becomes.... "C:\FullPathTo\SomeDir\SomeNameOfAnEXE.exe"

What command do I run to get the same behavior in Win 7 and Win XP?

I need to change the name of the window because we have scripts that run that use the window name to hook in commands.

share|improve this question
up vote 1 down vote accepted

It turned out to be an admin issue with Win 7. We worked around it with this.

start cmd.exe /k "cd SomeDirWeWantCWD & title NameOfWindow & ..\SomeDir\SomeNameOfAnEXE m"
share|improve this answer

You can enter the command title <NameOfWindow> for the window title to be set.

share|improve this answer
This changes the title of the command window. This does NOT change the title of the window that is launched from the "start" command. – Miebster Oct 22 '12 at 15:24
I've tried that on Windows 7 and it worked fine. I used the same syntax: start "Name" <Command>. But it was a Java process in my case. – AbhishekGirish Oct 22 '12 at 16:30
It appears to work for some things launched from cmd (but not all?) – Miebster Oct 22 '12 at 17:39
Is the application you launch a GUI? Setting the title always works in case of CLI applications. But if it's an application, the application has to be programmed to set the title. For example, if its a Java Swing UI, you will have to use Frame.setTitle() (or JFrame). – AbhishekGirish Oct 22 '12 at 17:52
What did u mean by "Did ya barf?" – AbhishekGirish Oct 22 '12 at 18:05

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.