Get Windows dir

PROKA

Well-known member
Joined
Sep 3, 2003
Messages
249
Location
Bucharest
whats the method to get the windows directory under vb.net ( doesnt seem to work with the getwindowsdirectory API )
 
C#:
/// <summary>
/// Returns the Windows Dir of the OS.
/// </summary>
/// <returns></returns>
public static string WinDir()
{
	DirectoryInfo di = new DirectoryInfo(Environment.SystemDirectory);
	return di.Parent.FullName;
}
 
Back
Top