If I use the same code in an installation section of the main page, it does work OK.
Simplified code sample of the main page:
The InstallDotNet2 function in my custom page contains the exact same code as Section x on the main page. If I comment out the Banner statements in the InstallDotNet2 function, everything works fine.; Pages
!insertmacro MUI_PAGE_COMPONENTS
Page custom PageDotNet2 InstallDotNet2
!insertmacro MUI_PAGE_INSTFILES
; Sections
Section x
; install .NET Framework 2.0
Banner::show /NOUNLOAD /set 76 $(InstallingNet2) $(PleaseWait)
ExecWait '"$REDISTRIBUTABLES_FOLDER\dotnetfx.exe"'
Banner::destroy
SectionEnd