views:

26

answers:

2

In executing
secedit /configure /db %~1\tomcat.sdb" /cfg %~1\2003.inf" /log %~1\dtomcat.log" /quiet
where
%~1 == C:\Program Files\myDirectory\mySubDirectory\mySuperSubDirectory

a file titled "C:\Program" is generated and within the file is the output for calling
secedit /?

I am curious as to why this is occuring because it makes it quite difficult to start certain services after an installation of a new product, for instance a PostGres windows service.

+1  A: 

You need to enclose the pathname in quotes:

"C:\Program Files\myDirectory\mySubDirectory\mySuperSubDirectory"

The space in "Program Files" is treated as a delimiter.

ChrisF
Thanks for the suggestion, however this solution here failed because of the extra ' " ' at the end of mySuperSubDirectory. +1 regardless :)
Woot4Moo
@Woot4Moo - Ah - well the answer is the missing quote before each % as system PAUSE points out.
ChrisF
+2  A: 

You appear to be missing quotes in a couple of places:

secedit /configure /db "%~1\tomcat.sdb" /cfg "%~1\2003.inf" /log "%~1\dtomcat.log" /quiet
                       ^                     ^                   ^
system PAUSE
Thanks, this fixed the issue quite effectively. This is what happens when I keep switching between *nix and windows
Woot4Moo