Archive: Hidden sections within Section Groups


Hidden sections within Section Groups
  If I dynamically change a sections text to "" to hide the section, if the Section Group it is in is checked, does it also check the hidden section?

I want to make sure that if I dynamically hide a section (say because the needed files don't exist on the users system), I want to make sure that if the SectionGroup it is located within does not still try installing that section when it is hidden.


If a section is hidden, I believe it will always be executed.

Edit: Well then, I have to hand you over to someone else as I don't know anything more on sections or section groups.


Well ALL of my sections already have the /o switch in front of them, so by default my installer has no sections checked.


basic answer: yes

The text of a section is separate of its flags, and any subgroup/item - even if hidden - still gets selected/deseleted if the parent gets selected/deselected.

Which means you basically have to add the following to the top of the sections that may get hidden;


  SectionGetText ${sectionID} $0

StrCmp$0 "" 0 +2
Abort
>
Where 'sectionID' needs to be replaced with whatever the ID of the section in question is.