IProductCatalog::SetCustomCatalogAttributes
Use this method to set the attributes of a custom catalog.
Definition
HRESULT IProductCatalog::SetCustomCatalogAttributes(_Recordset*pRSNewState,VARIANTfForceUpdate);
Parameters
pRSNewState
[in] A pointer to a Recordset object containing the new attributes.
fForceUpdate
[in, optional] A VARIANT that causes a forced update of the custom catalog attributes.
Return Values
This method returns an HRESULT indicating whether it completed successfully. See the Error Values section for more details.
Error Values
This method returns S_OK (0x00000000) to indicate success and either standard or custom COM HRESULT error values to indicate failure. For more information about standard COM errors, see Standard COM Errors.
The following table shows the custom COM error that this method can return.
Constant | Value | Description |
E_CAT_CANNOT_ALTER_CC |
0x88980060 | The specified changes could not be made. |
E_CAT_CUSTOMCATALOG_CHANGED | 0x88980035 | The custom catalog has been altered since it was last read. |
Additional information may be available using the global Err object, which can be accessed using the API function GetErrorInfo. In particular, the GetDescription method of the IErrorInfo interface may return a text description of the error.
Remarks
Use the SetCustomCatalogAttributes method to modify the CustomCatalogName attribute of a custom catalog. No other attributes can be modified. The pRSNewState parameter specifies a Recordset object that describes the new attribute values for this custom catalog. The method will fail if the custom catalog has already been published.
Use the Recordset object returned by the GetCustomCatalogAttributes method so that its timestamp can be compared for quality assurance.
For more information about memory ownership issues related to COM property and method parameters, see Managing COM Parameter Memory.