I try to build an application with different AppDomains and permissions. The starting application creates a new AppDomain B and uses CreateInstanceFrom to instantiate a class from a different dll. I can also assign different (standard) permissions to the permission set i use to create the AppDomain. So far, this works fine.
No i create a custom permission (in a different dll as mentioned in Implementing a Custom Permission) and try to add this permission to my permission set. Instantiating and assigning the permisson works, but when i call CreateInstanceFrom, a FileLoadException (HRESULT: 0x80131016) is thrown. I don't know why this exception is thrown... Does anyone know a solution to this? Thanks.
User contributions licensed under CC BY-SA 3.0