Function PostComp StrCpy $Drive1 0 ; HomeDir space StrCpy $Drive2 0 ; AuxDir space StrCpy $Drive3 0 ; DataDir space MessageBox MB_OK "Clearing Two Flags" !insertmacro ClearSectionFlag -FLIGHTWEATHERDATA 1 ; Disable these hidden sections !insertmacro ClearSectionFlag -FLIGHTVPFDATA 1 MessageBox MB_OK "Checking Home" !insertmacro SectionFlagIsSet HOME 1 +1 NoHome ; Skip ahead if the section is not selected SectionGetSize HOME $R0 IntOp $Drive1 $Drive1 + 1 NoHome: MessageBox MB_OK "Checking Data" !insertmacro SectionFlagIsSet DATA 1 +1 NoData SectionGetSize DATA $R0 IntOp $Drive2 $Drive2 + 2 NoData: MessageBox MB_OK "Checking Weather" !insertmacro SectionFlagIsSet FLIGHTWEATHER 1 +1 NoWeather SectionGetSize FLIGHTWEATHER $R0 IntOp $Drive1 $Drive1 + 4 !insertmacro SetSectionFlag -FLIGHTWEATHERDATA 1 SectionGetSize -FLIGHTWEATHERDATA $R0 IntOp $Drive2 $Drive2 + 8 NoWeather: MessageBox MB_OK "Checking VPF" !insertmacro SectionFlagIsSet FLIGHTVPF 1 +1 NoVPF SectionGetSize FLIGHTVPF $R0 IntOp $Drive1 $Drive1 + 16 !insertmacro SetSectionFlag -FLIGHTVPFDATA 1 SectionGetSize -FLIGHTVPFDATA $R0 IntOp $Drive3 $Drive3 + 32 NoVPF: MessageBox MB_OK "Checking Help" !insertmacro SectionFlagIsSet HELP 1 +1 NoHelp SectionGetSize HELP $R0 IntOp $Drive1 $Drive1 + 64 NoHelp: SectionSetSize DATA 0 SectionSetSize HOME 0 SectionSetSize FLIGHTWEATHER 0 SectionSetSize FLIGHTWEATHERDATA 0 SectionSetSize FLIGHTVPF 0 SectionSetSize FLIGHTVPFDATA 0 SectionSetSize HELP 0 MessageBox MB_OK "Drive1: $Drive1" MessageBox MB_OK "Drive2: $Drive2" MessageBox MB_OK "Drive3: $Drive3" FunctionEnd