CodeVerge.Net Beta


   Explore    Item Entry   Register  Login  
Microsoft News
Asp.Net Forums
IBM Software
Borland Forums
Adobe Forums
Novell Forums

ASP.NET Web Hosting – 3 Months Free!

Returns the directory information for the specified path string.

Namespace: ?System.IO
Assembly: ?mscorlib (in mscorlib.dll)

Syntax

Visual Basic (Declaration)
Public Shared Function GetDirectoryName ( _
	path As String _
) As String
C#
public static string GetDirectoryName(
	string path
)
Visual C++
public:
static String^ GetDirectoryName(
	String^ path
)
JavaScript
System.IO.Path.getDirectoryName = function(path);

Parameters

path
Type: System..::.String
The path of a file or directory.

Return Value

A String containing directory information for path, or null if path denotes a root directory, is the empty string (""), or is null. Returns Empty if path does not contain directory information.

Exceptions

ExceptionCondition
System..::.ArgumentExceptionThe path parameter contains invalid characters, is empty, or contains only white spaces, or contains a wildcard character.
System.IO..::.PathTooLongExceptionThe path parameter is longer than the system-defined maximum length.

See Also



Free Download:
  Privacy | Contact Us
All Times Are GMT