Archive: SectionSetFlags and AddSize


SectionSetFlags and AddSize
hi,

in my section I use AddSize

I mark installed components with flag (I think it's ${SF_SELECTED} | ${SF_RO})

StrCpy $1 64
SectionSetFlags ${secA} $1

after second click of checkbox of section
space required is 0.0 K

Thanks


64 is ${SF_PSELECTED} and shouldn't be set manually. It also doesn't include ${SF_SELECTED} and so the section is deselected and its size is reduced from the required size.


OK,
I shouldn't use it.

for info only:
if You compile and start the installer,
section is selected.
You can see space required is 0.0 K.
After clicking on section, space required is 1000.0 K
In both cases (for click and after click) section is selected in GUI.


!include "MUI.nsh"
OutFile "Basic.exe"

!define MUI_ABORTWARNING
!insertmacro MUI_PAGE_COMPONENTS
!insertmacro MUI_LANGUAGE "English"

Section test test_section_id
AddSize 1000
SectionEnd

Function .onInit
SectionSetFlags test_section_id 64
FunctionEnd

Thanks!