Home > .NET Framework > The official *managed* way to find the .NET Framework directory

The official *managed* way to find the .NET Framework directory

Keith blogs about "The official *managed* way to find the .NET Framework directory"

Keith BrownOct 19, 2005 –  Show original item

Earlier today I posted the official unmanaged way to get the .NET Framework directory. Of course I was using P/Invoke to do it 😉 Mike Woodring commented with an easier, managed way:

HttpRuntime.ClrInstallDirectory

But then Stephen Toub (my editor at MSDN Mag) commented with an even better option:

System.Runtime.InteropServices.RuntimeEnvironment.GetRuntimeDirectory()

Thanks guys!

Categories: .NET Framework
  1. No comments yet.
  1. No trackbacks yet.

Leave a comment