A dynamic assembly with the specified name and access mode.
This method should only be used to define a dynamic assembly in the current application domain. For more information, see the AppDomain.Load(System.Reflection.AssemblyName) method overload.
During the development of code that emits dynamic assemblies, it is recommended that you use an overload of the erload:System.AppDomain.DefineDynamicAssembly method that specifies evidence and permissions, supply the evidence you want the dynamic assembly to have, and include System.Security.Permissions.SecurityPermissionFlag.SkipVerification in refusedPermissions. Including System.Security.Permissions.SecurityPermissionFlag.SkipVerification in the refusedPermissions parameter ensures that the MSIL is verified. A limitation of this technique is that it also causes System.Security.SecurityException to be thrown when used with code that demands full trust.