_CatalogSets::CreateCatalogSet

Ee797742.c++_off(en-US,CS.10).gifEe797742.vb_on(en-US,CS.10).gif

Use this method to create a new catalog set in the catalog database.

Definition

HRESULT _CatalogSets::CreateCatalogSet(BSTRCatalogSetName,BSTRCatalogSetDescription,VARIANT_BOOLbWildCard,_Recordset*CatalogNamesRS,BSTR*CatalogSetID);

Parameters

CatalogSetName

[in] A BSTR that contains a name for the new catalog set. The maximum length is 128 characters.

CatalogSetDescription

[in] A BSTR that contains a description of the new catalog set.

bWildCard

[in] A VARIANT_BOOL that indicates whether this catalog set should automatically include all catalogs, including any new catalogs that might be created in the future. A value of True indicates that this catalog set includes all existing catalogs. A value of False indicates that this catalog set only includes a specific set of catalogs.

CatalogNamesRS

[in, optional] A pointer to an ActiveX Data Objects (ADO) _Recordset object that specifies the catalogs to be included in the new catalog set. The _Recordset object should contain a single column named CatalogName, and one row per catalog to be included. If the bWildCard parameter is True, then this parameter will be ignored.

CatalogSetID

[out, retval] A pointer to a BSTR used to return the automatically generated ID (GUID) of the new catalog set.

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 standard COM HRESULT error values to indicate failure. For more information about standard COM errors, see Standard COM Errors. 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

The CatalogSetID parameter contains valid data only if the new catalog set was created successfully.

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

See Also

CatalogSets Object


All rights reserved.