|
|
#1 |
|
Junior Member
Join Date: Jun 2003
Posts: 2
|
This is my first crack at NSIS. I'm using the modren interface. I created three custom dialog pages and I'm using them to capture data entered by the user (person installing). How do I store \ get \ access the values they entered?
My function looks like this so far: -------------------------------------------------------------------- Function SetCustomAPPNAME strcpy $1 "Choose APPNAME" strcpy $2 "[PI]AppName value stored the INI file." !insertmacro MUI_HEADER_TEXT $1 $2 !insertmacro MUI_INSTALLOPTIONS_DISPLAY "ioAPPNAME.ini" FunctionEnd -------------------------------------------------------------------- ioAPPNAME.ini resembles: -------------------------------------------------------------------- [Field 2] Type=Text MaxLen=4 MinLen=4 ValidateText=Must be 4 Characters in Length Left=10 Right=-80 Top=65 Bottom=75 -------------------------------------------------------------------- Basically I want to capture what they enter and then use in another section like this: ------------------------------------------------------------------- Section "INI File" SecINIFile ;Setup up INI file WriteINIStr $INSTDIR\dat\rerout.ini "Files" "log" <USER INPUT> SectionEnd ; end the section |
|
|
|
|
|
#2 |
|
Debian user
(Forum King) Join Date: Jan 2003
Location: Arch land
Posts: 4,917
|
Use for read:
code: * PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with MATE. * Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with MATE. |
|
|
|
|
|
#3 |
|
M.I.A.
[NSIS Dev, Mod] Join Date: Oct 2001
Location: Israel
Posts: 11,343
|
To make the code clearer it would be better to use:
!insertmacro MUI_INSTALLOPTIONS_READ $0 "ioAPPNAME.ini" "Field 2" "State" But Lobo's code should work too. NSIS FAQ | NSIS Home Page | Donate $ "I hear and I forget. I see and I remember. I do and I understand." -- Confucius |
|
|
|
|
|
#4 |
|
Junior Member
Join Date: Jun 2003
Posts: 2
|
Both work. Thanks a bundle. Where's all the documentation for all the macros for the modern GUI ?
|
|
|
|
|
|
#5 |
|
Major Dude
Join Date: Jun 2002
Location: Swindon, UK
Posts: 559
|
|
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|