共用方式為


DeleteDirectoryOption Enumeration 

Specifies what should be done when a directory that is to be deleted contains files or directories.

Remarks

This enumeration is used with the My.Computer.FileSystem.DeleteDirectory Method.

Members

Member Description

DeleteAllContents

Delete the contents of the directory along with the directory. Default.

ThrowIfDirectoryNonEmpty

Throw an IOException if the directory is not empty. The Data property of the exception lists the file(s) that could not be deleted.

Requirements

Namespace: Microsoft.VisualBasic.FileIO

Class: DeleteDirectoryOption

Assembly: Visual Basic Runtime Library (in Microsoft.VisualBasic.dll)

See Also

Tasks

How to: Delete a Directory in Visual Basic

Reference

My.Computer.FileSystem.DeleteDirectory Method
Microsoft.VisualBasic.FileIO.DeleteDirectoryOption