Hi all,

i want to add a commandline to registry. My Code is:
 Code:
$SUCCESS = 0
If ExistKey("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run") <> $SUCCESS
If AddKey("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run") <> $SUCCESS
? "AddKey failed with error code (" = @ERROR + ")"
Exit @ERROR<>0
Endif
Endif
If InGroup ("DENBG_All")
If WriteValue("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run","RunBGInfo","cmd.exe /c BGInfo\BGinfo.exe BGinfo\denbgAll.bgi /TIMER:0 /NOLICPROMPT","REG_SZ") = $SUCCESS
	? "Value written to registry successfully"
Else
	? "WriteValue failed with error code (" + @ERROR + ")"
Exit @ERROR<>0
Endif
Endif


The main part is this:

 Code:
If WriteValue("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run","RunBGInfo","cmd.exe /c BGInfo\BGinfo.exe BGinfo\denbgAll.bgi /TIMER:0 /NOLICPROMPT","REG_SZ") = $SUCCESS

but here I should insert following to this reg key or it does not work

"cmd.exe /c "BGInfo\BGinfo.exe BGinfo\denbgAll.bgi" /TIMER:0 /NOLICPROMPT"

and the quotation marks (here bold) does not work. Kixtart tells an error that it is missing commas.If I delete these, the command will not work.

The Idea is to run bginfo every time local, so it would also work if the notebooks have no network connection.

Any ideas?

Thank you very much
Stefan