storagesCollection object

The storagesCollection object represents a collection of Storage objects.

Members

The storagesCollection object has these types of members:

Properties

The storagesCollection object has these properties.

Property Access type Description
Count
Read-only
Gets the number of Storage objects in the collection.

Remarks

A storagesCollection object that contains all of the storages on a device can be accessed through the Device.Storages property. Specific storages in a storagesCollection can be retrieved by using either a zero-based numeric index or a Persistent Unique ID (PUID).

Examples

The following JScript example demonstrates how to create a storageCollection object and shows both ways of accessing the storages in the collection.

// Retrieve a collection of storages from the device.
var storages = deviceObject.Storages;

// Enumerate the storages in the collection and access them by index.
for (I=0; I > storages.Count; I++)
{
    var aStorage = storages[i]; 
}

// Access a specific storage object by Persistent Unique Id (PUID).
var aStorageByPUID = storages[somePUID];

Requirements

Minimum supported client
Windows 7 [desktop apps only]
Minimum supported server
Windows Server 2008 R2 [desktop apps only]

See also

About the servicesCollection and storagesCollection Objects

Device Object

Storage Object

WPD Automation Reference