komsbomb
23rd February 2006 14:26 UTC
ReadRegStr, error compile if the key contains space
I've found I should add '' to the quote.
Don't bother with this question any more.
-------------------------------------
I'm very newbie to NSIS.
!define KEYNAME "xxx yyy"
ReadRegStr $0 HKLM '${KEYNAME}' "subkeyname"
Error compile with above line,
Error, "ReadRegStr expects 4 parameters, got 5."
I believe it's caused by the space between xxx and yyy, but the space is one part of the key name.
How to solve that?
Thanks.
Davion
27th February 2006 12:44 UTC
I tried with code below and it worked fine, with your key/subkey it worked to...
maybe you have to use a " instead a '
Name "RegPoop"
OutFile "RegPoop.exe"
!define KEYNAME "SOFTWARE\Microsoft\Advanced INF
Setup\IE40.BrowseUI"
Section
ReadRegStr $0 HKLM "${KEYNAME}" "ComponentVersion"
MessageBox MB_OK "$0"
SectionEnd
Greetz Davion
Afrow UK
27th February 2006 16:01 UTC
I've found I should add '' to the quote.
Don't bother with this question any more.
-Stu