In my code I need to set a process to connect it to a certain profiler. I understand that this is what I would have to do:
ProcessStartInfo processStartInfo = new ProcessStartInfo(exePath);
processStartInfo.EnvironmentVariables["Cor_Enable_Profiling"] = "0x1";
processStartInfo.EnvironmentVariables["COR_PROFILER"] = "{B146457E-9AED-4624-B1E5-968D274416EC}";
processStartInfo.UseShellExecute = false;
The issue now is that I don't know, for the profiler of my choice, how to set processStartInfo.EnvironmentVariables["COR_PROFILER"]
, is there any place that I can find out the mapping between the profiler application name and the profiler GUID?