From: "Yussef Alkhamrichi"
Hope someone out there puts together a custom HttpModule and tries this out, I will continue to search if I can find this bug (sadly there isn't a way to hack into the config file loading of .NET).
I tried a simple Hello HttpModule and on first try:
Server Error in '/TestHttpModules' Application. The module 'HelloWorldModule' is already in the application and cannot be added again
Tried remove in web.config
Line 2: <system.web> Line 3: <httpModules> Line 4: <remove name="HelloWorldModule" /> Line 5: <add name="HelloWorldModule" Line 6: type="HelloWorldModule, HelloWorldModule" />
Parser Error Message: There is no 'HelloWorldModule' module in the application to remove.
Tried blocking out the "whole name" this time...
<httpModules>
<!-- <remove name="HelloWorldModule" />
<add name="HelloWorldModule"
type="HelloWorldModule, HelloWorldModule" /> -->
</httpModules>System.Threading.ThreadAbortException: Thread was being aborted.
Adding a clear works
<configuration>
<system.web>
<httpModules>
<!-- <remove name="HelloWorldModule" /> -->
<clear />
<add name="HelloWorldModule"
type="HelloWorldModule, HelloWorldModule" />
</httpModules>
</system.web>
</configuration>Moving clear to bottom
<httpModules>
<!-- <remove name="HelloWorldModule" />
<clear /> -->
<add name="HelloWorldModule"
type="HelloWorldModule, HelloWorldModule" />
<clear />
</httpModules>runs with no error but not httpmodules output either!
Seems mod_aspdotnet needs a clear first as you said!
Jeff
