Attach .Net Profiler at RunTime to a running process

Rajeshwari kanchiraju 1 Reputation point
2021-11-03T04:47:42.13+00:00

Hi ,

I have been trying to attach the .Net Profiler at Runtime to a running process using the PID information .

I could able to use attachprofiler() method and call Initializeforattach() method.

Im trying to set the masks -"COR_PRF_ENABLE_REJIT" & "COR_PRF_DISABLE_ALL_NGEN_IMAGES" inside the initializeforattach() method using "SetEventMask()" method but its getting failed.

Inside the Initializeforattach() , I have used "ICorProfilerInfo4" object for QueryInterface().

@Brian Please help me why seteventmasks() getting failed and unable to load the modules.

Any reference is much appreciated.

Thanks in advance.

.NET Runtime
.NET Runtime
.NET: Microsoft Technologies based on the .NET software framework.Runtime: An environment required to run apps that aren't compiled to machine language.
1,119 questions
{count} votes