|
|
#1 |
|
Junior Member
|
Ok, so I have this installer that installs a mod for a game, and you need to configure certain settings in this file to get it set up.
I'm using the function from the wiki: http://nsis.sourceforge.net/Write_to...le_line_number Now, the problem is, it's deleting the file! Is there a better function to use? The file is already written when I install, and I'm going into the file and replacing certain lines with a different value depending on what the user said. I know what the line number is that I need to replace, so I don't need a function to search - just to replace a whole line. Last edited by Joudoki; 15th July 2006 at 16:33. |
|
|
|
|
|
#2 |
|
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
Use ConfigWrite from the NSIS documentation. It's under Useful Headers.
-Stu |
|
|
|
|
|
#3 |
|
Junior Member
|
Ok, one other problem I need to enable/disable some text boxes depending on the state of a checkbox. Any way to do this? I did a search and I only came up with some old threads from years past.
|
|
|
|
|
|
#4 |
|
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
Have a look at Examples\InstallOpions\testnotify.nsi
-Stu |
|
|
|
|
|
#5 |
|
Junior Member
|
Ah, that won't work, Afrow. Here's what my file looks like: (It's LUA)
code: Well, for example, I need to replace the first line with ECS_ADMINS_IMPORTULX = false; or ECS_ADMINS_IMPORTULX = true;, depending on what the user says. |
|
|
|
|
|
#6 |
|
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
This is probably better for what you need then:
http://nsis.sourceforge.net/Replace_...ecified_string -Stu |
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|