CatalogManager.RemovePropertyValue
Use this method to remove a defined value from an enumeration property.
Definition
Sub RemovePropertyValue(strPropertyName As String,strLegalValue As String)
Parameters
strPropertyName
A String that contains the name of the enumeration property from which the specified value will be removed.
strLegalValue
A String that contains the defined value to be removed as a choice from the specified enumeration 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 property did not exist. |
E_CAT_PROP_NOT_ENUM | &H88980007 | The specified property was not of type cscEnumeration. Call this method only for enumeration type properties. |
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.
Caution
- When a value is removed from an enumeration type property all products that have that property set to that value will have the value changed to NULL.
Example
myCatalogManager.RemovePropertyValue "Color", "Pink"
See Also
CatalogManager.AddPropertyValue