|
|
#1 | ||
|
Junior Member
Join Date: Oct 2007
Posts: 2
|
Having problems with trailing backslash
I've created my first NSIS script (makes you cringe when you see that in a post, I'm sure) and I used the EclipseNSIS plug-in for Eclipse. I'm installing a file, adding a registry key, and adding string values to the registry key. Someone else has inherited the development of the program I'm installing and I'm trying to help him deploy it. I've spent hours searching the forums, looking in the docs/faqs, and searching Google. I haven't found anything to get this to work or maybe I'm just too tired right now.
One of the string values added to the registry is Quote:
code: Compiling gives me this error: Quote:
code: which is how it gets 8 parameters in the error. I do not have control over the $ and the trailing backslash. I have tried many different variations of $$, \\, and all three types of quotes. I've managed to just get warnings, but the output is never right in the registry. I end up with multiple "$"s, multiple "\"s, no "$", and/or no trailing "\" at the end of the string value in the registry. Removing the trailing backslash allows the script to compile and run just fine (except now I do not have the trailing backslash). Can someone figure this out? If not, perhaps I'll look at getting NSIS to run an embedded cmd script that loads an embedded .reg file. I was just (futilely) trying to keep it all NSIS. Maybe the answer is to add the string without the trailing backslash and then concatenate the trailing backslash. Perhaps I'll see how to do that tomorrow. Thank you in advance for any help/suggestions. |
||
|
|
|
|
|
#2 |
|
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
Use quotes around the path.
Stu |
|
|
|
|
|
#3 | |||||
|
Junior Member
Join Date: Oct 2007
Posts: 2
|
Afrow, I had tried that with ", ', and ` quotes around that parameter.
Using ": code: I get this error: Quote:
code: I get this error: Quote:
code: I get this error: Quote:
code: Now it will compile and run, but the string in the registry has double quotes around it (i.e., Quote:
Quote:
Any other ideas? Should I just pull out the quotes after writing the string? Can you do that? Like I said before, I’ve tried all different kinds of combinations with the dollar sign, the backslash, and the 3 different quotes, like …$$\, …$$\\, “…$$\\â€, etc., but I’m not the pro like most of you out there providing help. I was hoping someone more familiar with the syntax or NSIS scripting could tell the correct way to write this line or how to get around this issues. Thank you and I apologize for the long posts. I just want to make sure I'm being thorough. |
|||||
|
|
|
|
|
#4 |
|
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
"\\server\share\folder\"
Stu |
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|