bbh
13th March 2002 00:33 UTC
disable a section based on an error
Hi,
I have a section of my installer that I don't want run if there has been an error in a previous section. Right now I have it set up like:
Section SectionB
IfErrors SkipSectionB
MessageBox MB_OK "Do stuff in section B"
SkipSectionB:
SectionEnd
So basically I call "SetErrors" in the previous section. If any error occurred, then sectionB is skipped.
This works, but I was wondering if there is a better way to accomplish the same thing.
Thanks,
Beth
bballer182
13th March 2002 04:53 UTC
looking for
the way that you have it setup now looks good. Are you looking for a way to involve the user less, something that take less script, or something that runs faster?
bbh
13th March 2002 16:55 UTC
Not necesarily any of those options.
I just was wondering if there was a better (i.e. cleaner) way of disabling a section. I wasn't able to find a way to do this except for ensuring the error flag is set in a previous section and then checking that value before continuing in the new section. I suppose I could accomplish the same thing by using a variable other than the error flag.
Like I said, it works. I was just wondering if there were other ways to accomplish the same thing.
Thanks,
Beth