Well - I've tried to cut it down to it's bare essentials, but it's a big script, and there's a whole lot of stuff that depends on other stuff so it's hard to cut things out without getting errors.
So I'll try to post the most essential parts that has to do with this problem instead.
First, one of the sections(the one I'm having problems with):
Section "Testing testing." Sec01
SectionIn RO
SetDetailsPrint textonly
DetailPrint "Extracting And Installing Files... Please Wait."
SetDetailsPrint none
ReadRegStr $0 HKCU "Software\${VER_NAME}\Sections" "01"
${if} $0 == 1
Goto AlreadyInstalled
${endif}
LOTS OF STUFF DOWN HERE, BUT NOT IMPORTANT, JUST FILES TO EXTRACT ETC.
then on to
.onInit:
ReadRegStr $0 HKCU "Software\${VER_NAME}\Sections" "01"
${if} $0 == 1
!insertmacro UnselectSection ${Sec01}
SectionSetText ${Sec01} ""
${endif}
(one of those for each section)
Then there's
-post:
Section -post
ReadRegStr $0 HKCU "Software\${VER_NAME}\Sections" "01"
${if} $0 == 1
Goto +4
${else}
SectionGetFlags ${Sec01} $0
WriteRegStr HKCU "Software\${VER_NAME}\Sections" "01" $0
${endif}
(one of those for each section)
And I have some similar ones in the un.onInit and un.post parts of the script.
And in each of the uninstall sections, there's one of these:
WriteRegStr HKCU "Software\${VER_NAME}\Sections" "01" "0"
That's all I can see that can play any part in the problem.
Again - what I want is for the installed sections to disappear from the components page when the installer is
reopened. This
works already, for all sections, even the one I'm having problems with. The ONLY thing that mucks things up, is if I add the
SectionIn RO to the section. Then, when it's installed and I reopen the installer, it's still there. If I REMOVE only the
SectionIn RO line, save and compile, ALL sections are gone from the installer when reopened (as I want them to be), if all the components were installed.