Hey I'm having some difficulty using NSIS to edit a wordpad file during an install and I was hoping someone could help me out.
Basically, I need to add two lines of text to an enviroment file that uses WordPad's wacky rtf format but no matter what I do it always comes out as one line.
Here's what I'm currenly doing:
FileOpen $0 "C:Myfile.env" a
FileSeek $0 0 END
FileWrite $0 "Line 1 \n Line 2"
FileClose $0
I've even tried to open, find the end and close the file once for each line FileOpen but no matter what, I can't insert a newline.
Can anyone help me out with this? Do I have to use Ascii, Unicode, Magic beans? If I do, how do I do it?!
Thanks for the help!
NSIS and WordPad
2 posts