RemoveVirtualCatalogRule Method

Removes an inclusion or exclusion rule from a base catalog.

Namespace:  Microsoft.CommerceServer.Catalog
Assembly:  Microsoft.CommerceServer.Catalog (in Microsoft.CommerceServer.Catalog.dll)

Syntax

'Declaration
Public Sub RemoveVirtualCatalogRule ( _
    catalogName As String, _
    categoryName As String, _
    productId As String, _
    variantId As String _
)
'Usage
Dim instance As VirtualCatalog
Dim catalogName As String
Dim categoryName As String
Dim productId As String
Dim variantId As String

instance.RemoveVirtualCatalogRule(catalogName, _
    categoryName, productId, variantId)
public void RemoveVirtualCatalogRule(
    string catalogName,
    string categoryName,
    string productId,
    string variantId
)
public:
void RemoveVirtualCatalogRule(
    String^ catalogName, 
    String^ categoryName, 
    String^ productId, 
    String^ variantId
)
public function RemoveVirtualCatalogRule(
    catalogName : String, 
    categoryName : String, 
    productId : String, 
    variantId : String
)

Parameters

  • productId
    Type: System..::.String
    The product identifier for the product in the base catalog.
  • variantId
    Type: System..::.String
    The variant identifier for the product in the base catalog.

Exceptions

Exception Condition
ValidationException

The rule is invalid.

Remarks

You can use this method to remove inclusion and/or exclusion rules from one or more base catalogs. To remove a catalog level rule from a catalog, set the categoryName, productId, variantId to nullNothingnullptra null reference (Nothing in Visual Basic). To remove a category rule from a catalog, set the categoryName to the category name and the parameters productId , variantId to nullNothingnullptra null reference (Nothing in Visual Basic). To remove a product rule from a catalog, set the productId to the product ID and the parameters categoryName, variantId to nullNothingnullptra null reference (Nothing in Visual Basic). To remove a variant rule from a catalog, set the productId to the product ID, variantId to the variant ID and the parameter categoryName to nullNothingnullptra null reference (Nothing in Visual Basic). Call the Save method to save the changes to the catalog system. Call the Rebuild method to apply the rules to the virtual catalog.

Permissions

See Also

Reference

VirtualCatalog Class

VirtualCatalog Members

Microsoft.CommerceServer.Catalog Namespace