Jaa


KnownFolders.RemovableDevices Property

Definition

Gets the removable devices folder.

public:
 static property StorageFolder ^ RemovableDevices { StorageFolder ^ get(); };
static StorageFolder RemovableDevices();
public static StorageFolder RemovableDevices { get; }
var storageFolder = KnownFolders.removableDevices;
Public Shared ReadOnly Property RemovableDevices As StorageFolder

Property Value

The removable devices folder.

Windows requirements

App capabilities
removableStorage

Remarks

Prerequisites

To access the removable devices folder, you must:

  • In the app manifest, specify the Removable Storage capability.
  • In the app manifest, register at least one File Type Association declaration. This declaration explicitly indicates the file types (extensions) that your app wants to access on the removable devices. The app can only enumerate, create, or change files that have the file types declared in the app manifest. For more info, see Handle file activation.

Return value

To work with the removable devices folder and its contents, call the methods and properties of the StorageFolder class. For general info about how to use files and folders, see Enumerate and query files and folders.

The folder returned by the RemovableDevices property is a virtual folder. This virtual folder contains a subfolder for each removable device that's present. For example, if a single removable device is attached to the computer, the removable devices folder contains a single subfolder for which the name and path may be D:\.

If no removable devices are available, reading the value of this property returns an empty folder. It does not raise an exception.

Applies to

See also