简体   繁体   中英

Loading managed dll into AppDomain from native c++ code

I want to load managed assembly into the AppDomain from native c++ code.
If it worth something the native code is a CLR profiler so I get notification each time AppDomain is created.

我相信您需要托管CLR

You're probably looking for ICLRRuntimeHost::ExecuteInDefaultAppDomain() . It will load an assembly into the default AppDomain. You asked about loading into "the" AppDomain, so presumably you don't care about other non-default AppDomains.

ICLRRuntimeHost is a COM interface, and thus available to native code.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM