ICatalogManager3::GetDefinitionProperties Method [C++]

Use this method to return the properties of the specified catalog or product definition.

Definition

[C++]

HRESULT ICatalogManager3::GetDefinitionProperties(BSTRstrDefinitionName,
  _Recordset**ppRSProperties);

[Visual Basic]

Function GetDefinitionProperties(strDefinitionName As String) As _Recordset

Parameters

  • strDefinitionName[C++]
    [in] A BSTR that contains the name of the definition whose properties will be returned.
  • strDefinitionName[Visual Basic]
    A String that contains the name of the definition whose properties will be returned.
  • ppRSProperties[C++]
    [out, retval] A pointer to a _Recordset object used to return the properties of the definition.

Return Values

[C++] This method returns an HRESULT indicating whether it completed successfully. See the Error Values section for more details.

[Visual Basic] If this method completes successfully, it returns a Recordset that contains the properties of the specified definition.

Error Values

[C++] 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.

[Visual Basic] 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.

Name Value Description
E_CAT_CATMGR_NOT_INITIALIZED

[C++] 0x889800B

[Visual Basic] &H8898005

The CatalogManager object has not been initialized. The CatalogManager object should be initialized before calling this method.
E_CAT_INVALID_RS_POINTER

[C++] 0x889800B

[Visual Basic] &H8898007

The recordset pointer that you specified is invalid.
E_CAT_INVALID_DEFINITION_LENGTH

[C++] 0x889800E

[Visual Basic] &H889800A

The definition name that you specified is invalid. Definition names should be between 1 and 128 characters in length.
E_CAT_DEFINITION_DOESNT_EXIST

[C++] 0x8898000

[Visual Basic] &H889800B

The Definition you specified does not exist.

[C++] 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.

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

Remarks

[C++] The ppRSProperties parameter contains valid data only if the method completes successfully.

[Visual Basic] The recordset returned by this method contains valid data only if the method completes successfully.

The following tables shows the fields in the returned recordset.

Field Data Type Description
DefinitionID Integer The number that uniquely identifies the definition.
PropertyName String
128 characters
None
PropertyOrder Integer None
PropertyType Integer Zero (0) indicates product or category, one (1) indicates variant property.
TimeStamp timestamp None

The rows of the recordset are sorted on the PropertyOrder field.

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

[Visual Basic]

Example

Set rsDefProps = myCatalogManager.GetDefinitionProperties("T-Shirts")

See Also

[C++]CatalogManager Object

[Visual Basic]CatalogManager Object

[C++]ICatalogManager3::AddDefinitionProperty

[Visual Basic]CatalogManager.AddDefinitionProperty

[C++]ICatalogManager3::AddDefinitionVariantProperty

[Visual Basic]CatalogManager.AddDefinitionVariantProperty

[C++]ICatalogManager3::RemoveDefinitionProperty

[Visual Basic]CatalogManager.RemoveDefinitionProperty

Copyright © 2005 Microsoft Corporation.
All rights reserved.