ERROR after starting this command in the batch file. WHY ?

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
ogneniq_kinjal
Posts: 3
Joined: 24 Nov 2007 13:44
Location: Bulgaria, Sofia

ERROR after starting this command in the batch file. WHY ?

#1 Post by ogneniq_kinjal » 24 Nov 2007 14:18

Hi. I'm from Bulgaria and first of all i want to excuse myself if there is some kind of missunderstanding because "english" is not my native language.

So, i wrote a batch file containing this command

reg add HKLM\software\microsoft\windows NT\CurrentVersion\winlogon\specialaccounts\UserList /v IE_USR /t REG_DWORD /d 0

and my problem is that after starting the batch file nothing happens. Also i wrote the command into the command prompt but this error replies

Error: Too many command-line parameters

I will be very grateful, if someone can help me, solving this problem.

DosItHelp
Expert
Posts: 239
Joined: 18 Feb 2006 19:54

#2 Post by DosItHelp » 25 Nov 2007 14:55

Hi ogneniq_kinjal,

When a registry path has spaces in it then you need to put it in quotes, like this:

Code: Select all

reg add "HKLM\software\microsoft\windows NT\CurrentVersion\winlogon\specialaccounts\UserList" /v IE_USR /t REG_DWORD /d 0


If you have a batch file and want to keep it open when finished then use the PAUSE command as the last command.

DOS IT HELP?

ogneniq_kinjal
Posts: 3
Joined: 24 Nov 2007 13:44
Location: Bulgaria, Sofia

#3 Post by ogneniq_kinjal » 26 Nov 2007 11:56

DosItHelp wrote:Hi ogneniq_kinjal,

When a registry path has spaces in it then you need to put it in quotes, like this:

Code: Select all

reg add "HKLM\software\microsoft\windows NT\CurrentVersion\winlogon\specialaccounts\UserList" /v IE_USR /t REG_DWORD /d 0


If you have a batch file and want to keep it open when finished then use the PAUSE command as the last command.

DOS IT HELP?


Thank you very much. It worked that way.

Post Reply