Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

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

I'm trying to write a little batch script which is supposed to backup all printers on a Win2008 print server using printbrm. Here's what I've got so far:

%comspec% /c spool\tools\printbrm -B -S \\SERVERNAME -F Print_Backup.printerExport -O FORCE

All this does is open a command shell, just to close it instantly, though I have no idea why. Can anyone help me out?

share|improve this question

You probably want to use the full path %WINDIR%\System32\Spool\Tools, there's no guarantee that %comspec% will start in the right directory.
The /c will make the script close as soon as it's done so add a pause as the last line of the batch file to see what messages show up.

share|improve this answer
up vote 0 down vote accepted

I was able to workaround the problem by simply adding a 'del' clause at the beginning of the script. It seems like the option '-o force' wasn't really doing what it was supposed to.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .