I have an asp.net page that uses a DLL built in C# with an inherited windows control. When an event fires, a javascript function handles it. Everything works fine.

Whenever I re-compile the DLL to the asp.net folder in wwwroot, view the asp.net page, and fire an event from the control, I get the Microsoft .NET Framework message "The application attempted to perform an operation not allowed by the security policy. The operation required the SecurityException. To grant this application the required permission please contact your system administrator, or use the Microsoft .NET security policy administration tool..."

So I have to go to the Start Menu->Programs->Administrative Tools->Microsoft .NET Framework 1.1 Wizards->Trust an Assembly, browse for the DLL, set the trust level, and click OK. This is quite a hassle to do every time I re-compile the DLL. Could I write a script or .bat file to set this, set it and forget it, or just do away with it all together?

It would really be a pain if users browsing my asp.net page had to do this everytime I re-compiled.