Export (0) Print
Expand All

IStorage::SetClass method

The SetClass method assigns the specified class identifier (CLSID) to this storage object.

Syntax


HRESULT SetClass(
  [in]  REFCLSID clsid
);

Parameters

clsid [in]

The CLSID that is to be associated with the storage object.

Return value

This method can return one of these values.

S_OK

The CLSID was successfully assigned.

E_PENDING

Asynchronous Storage only: Part or all of the storage's data is currently unavailable. For more information see IFillLockBytes and Asynchronous Storage.

STG_E_ACCESSDENIED

The caller does not have enough permissions for assigning a CLSID to the storage object.

STG_E_MEDIUMFULL

Not enough space was left on device to complete the operation.

STG_E_REVERTED

The storage object has been invalidated by a revert operation above it in the transaction tree.

Remarks

When first created, a storage object has an associated CLSID of CLSID_NULL. Call SetClass to assign a CLSID to the storage object.

Call the IStorage::Stat method to retrieve the current CLSID of a storage object.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps | Windows Store apps]

Minimum supported server

Windows 2000 Server [desktop apps | Windows Store apps]

Header

Objidl.h

IDL

Objidl.idl

Library

Uuid.lib

DLL

Ole32.dll

IID

IID_IStorage is defined as 0000000B-0000-0000-C000-000000000046

See also

IStorage - Compound File Implementation
IStorage::Stat

 

 

Community Additions

ADD
Show:
© 2014 Microsoft