I wrote a small profiler for .NET applications. It uses an interface ICorProfilerCallback2.
The profiler joins and works well for a .NET 2.0 application, but does not work for .NET> 2.0 (3.0, 3.5, 4.0). When I run exe compiled with .NET 4.0, nothing happens, but for .NET 2.0, the profiler starts. I set the following variables before running a managed exe
@Echo off
set Cor_Enable_Profiling=0x1
set COR_PROFILER={67D8965A-8686-2639-9C24-E1F7D13EE105}
set COR_PROFILER_DLL=e:\Debug\Profiler.dll
set COR_PROFILER_PATH=e:\Debug\Profiler.dll
Any idea why this might happen? He doesn't even fall intoDllMain
source
share