Click here to Skip to main content
15,891,864 members

Comments by wknopf (Top 1 by date)

wknopf 7-Feb-11 12:51pm View    
Deleted
that's nicer, no interop necessary
using System.Diagnostics;

public static bool RunningInVisualStudio()
{
string appName = Process.GetCurrentProcess().MainModule.FileName.ToString();
return (appName.Contains(".vshost."));
}