Category.RemoveChildCategory

Ee823976.c++_on(en-US,CS.10).gifEe823976.vb_off(en-US,CS.10).gif

Use this method to remove a category that is a child of this category.

Definition

Sub RemoveChildCategory(strCategoryName As String)

Parameters

strCategoryName

A String that contains the name of the category to be removed as a child of this category.

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_CATEGORY_DOESNT_EXIST &H8898001C The category you specified either did not exist or was not a child of this category.

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

Remarks

Use the RemoveChildCategory method to remove a child category from this category. If the category named in the strCategoryName parameter does not exist, then this method will fail.

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

Example

myCategory.RemoveChildCategory "T-Shirts"

See Also

Category Object

Category.AddChildCategory

Category.RemoveParentCategory


All rights reserved.