CatalogManager.RenameProperty

Ee825080.c++_on(en-US,CS.10).gifEe825080.vb_off(en-US,CS.10).gif

Use this method to rename a property.

Definition

Sub RenameProperty(strOldPropertyName As String,strNewPropertyName As String)

Parameters

strOldPropertyName

A String that contains the existing name of the property.

strNewPropertyName

A String that contains the wanted name of the property.

Return Values

None.

Error Values

This method sets the Number property of the global Err object to S_OK (&H00000000) to indicate success and to either standard or custom COM error values to indicate failure. For more information about standard COM errors, see Standard COM Errors.

The following table shows the custom COM errors that this method can return.

Constant Value Description
E_CAT_PROP_DOESNT_EXIST &H88980005 The specified old property name did not exist.
E_CAT_PROP_EXISTS &H88980003 A property with the specified new property name already existed.
E_CAT_PROP_IS_ID &H88980011 The property name you specified was used as a ProductID or VariantID of a catalog. These properties are specified when a catalog is created and cannot be renamed or deleted.

Additional information may be available using the global Err object. In particular, the Description property may contain a text description of the error.

Remarks

For more information about memory ownership issues related to COM property and method parameters, see Managing COM Parameter Memory.

Example

myCatalogManager.RenameProperty "Weight", "Wt."

See Also

CatalogManager Object

CatalogManager.RenameDefinition


All rights reserved.