나는 여기에 동적으로 NSIS 스크립트를 사용하여 customPage.ini가NSIS : 사용자 정의 페이지의 콤보 상자 값에 액세스 하시겠습니까?
; Ini file generated by the HM NIS Edit IO designer.
[Settings]
NumFields=2
[Field 1]
Type=Label
Text=Select Version:
Left=4
Right=53
Top=16
Bottom=26
[Field 2]
Type=Combobox
Text=Combobox
ListItems=
Left=53
Right=138
Top=14
Bottom=107
내가 콤보 상자의 값을 설정하려면 파일 코드 여기
.
.
.
; Welcome page
!insertmacro MUI_PAGE_WELCOME
Page custom customPage "" ": custom page"
.
.
.
Function customPage
GetTempFileName $R0
File /oname=$R0 customPage.ini
InstallOptions::dialog $R0
Pop $R1
StrCmp $R1 "cancel" done
StrCmp $R1 "back" done
StrCmp $R1 "success" done
error: MessageBox MB_OK|MB_ICONSTOP "InstallOptions error:$\r$\n$R1"
done:
FunctionEnd
.
.
.
는, INI 파일을 사용 NSIS 설치에 사용자 정의 페이지를 추가했습니다 , 어떻게 nsis에서 콤보 박스에 액세스 할 수 있습니까?
아론 (Aaron)과 마찬가지로 GetTempFileName을 사용하면 자동으로 삭제되므로 $ pluginsdir을 넣는 것이 가장 좋습니다. – Anders
이것은 훌륭합니다! 하나의 의견이지만, 당신이 코드 조각에서 "State"를 "ListItems"로 바꿀 ListItem의 옵션을 변경하려면 –