Share via


GetDirectories Method

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Returns the subdirectories of the current directory.

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

Syntax

'Declaration
Public Function GetDirectories As DirectoryInfo()
public DirectoryInfo[] GetDirectories()
public:
array<DirectoryInfo^>^ GetDirectories()
member GetDirectories : unit -> DirectoryInfo[] 
public function GetDirectories() : DirectoryInfo[]

Return Value

Type: array<System.IO. . :: . .DirectoryInfo> [] () [] []
An array of DirectoryInfo objects.

Remarks

If there are no subdirectories, this method returns an empty array. This method is not recursive.

.NET Framework Security

See Also

Reference

DirectoryInfo Class

System.IO Namespace