Xeijin Posted February 4, 2007 Share Posted February 4, 2007 (edited) I'm having a spot of trouble with the %programfiles% variable.I'm trying to use it to update the virus definitions after Symantec Antivirus 10 Installs, during RunOnceEx"%programfiles%\Symantec AntiVirus\VPDN_LU.exe /S" /fHowever, the problem seems to be that when it comes to executing this, Windows has trouble with the space in 'Program Files' (which is obviously where %programfiles% resolves to) I'm sure I'm doing something wrong, like missing a quote or something but quite frankly I'm stumped, and I'd appreciate it if someone else could point me in the right direction TIA,// Xeijin Edited February 4, 2007 by Xeijin Link to comment Share on other sites More sharing options...
phkninja Posted February 4, 2007 Share Posted February 4, 2007 (edited) firstly did you try %ProgramFiles% as this is the environment variable in winxp.go run->cmdtypesetThis will show the environment variable currently definedSecondly what kind of error are you getting? (it might be helpful to know what we are trying to solve) Edited February 4, 2007 by phkninja Link to comment Share on other sites More sharing options...
cluberti Posted February 4, 2007 Share Posted February 4, 2007 You either need to add quotes around the command line to use the variable, or you need to substitute the 8.3 path instead of the variable for the command to work. I see you've got it in runonceex format, so it should probably look like this:"\"%programfiles%\Symantec AntiVirus\VPDN_LU.exe\" /S" /f Link to comment Share on other sites More sharing options...
Xeijin Posted February 4, 2007 Author Share Posted February 4, 2007 Hi phkninja,Sorry I should have explained it better:The error is a critical one, and is basically saying that it can't find "C:\Program " which I'm assuming is because of something to do with the space in between 'Program Files'.// Xeijin Link to comment Share on other sites More sharing options...
phkninja Posted February 4, 2007 Share Posted February 4, 2007 yep seen that one before, when i used %ProgramFiles% it work ok for me.The only true way to know is to use the 8.3 naming as cluberti suggested (or the runonceex mod he gave) Link to comment Share on other sites More sharing options...
Xeijin Posted February 5, 2007 Author Share Posted February 5, 2007 Thanks, Cluberti's method works perfectly now!// Xeijin Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now