Microsoft SDK for Java

RenameElement

This method of the IStorage interface renames the specified substorage or stream in this storage object.

Syntax

public void RenameElement(String pwcsOldName, String pwcsNewName);

Return Value

S_OK -- The element was successfully renamed.

E_PENDING -- Asynchronous storage only: Part or all the element's data is currently unavailable.

STG_E_ACCESSDENIED -- The caller does not have sufficient permissions for renaming the element.

STG_E_FILENOTFOUND -- The element with the specified old name does not exist.

STG_E_FILEALREADYEXISTS -- The element specified by the new name already exists.

STG_E_INSUFFICIENTMEMORY -- The element was not renamed due to a lack of memory.

STG_E_INVALIDNAME -- Invalid value for one of the names.

STG_E_INVALIDPOINTER -- The pointer specified for the element was invalid.

STG_E_INVALIDPARAMETER -- One of the parameters was invalid.

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

STG_E_TOOMANYOPENFILES -- The element was not renamed because there are too many open files.

Parameters

pwcsOldName [in] Points to a wide character string that contains the name of the substorage or stream to be changed.
pwcsNewName [in] Points to a wide character string that contains the new name for the specified substorage or stream.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.