Share via


AddEnumerationPropertyValue Method (String)

For the latest version of Commerce Server 2007 Help, see the Microsoft Web site.

Adds an enumeration value to the current enumerated property with the specified enumeration value.

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

Syntax

'Declaration
Public Sub AddEnumerationPropertyValue ( _
    enumValue As String _
)
'Usage
Dim instance As CatalogEnumerationProperty
Dim enumValue As String

instance.AddEnumerationPropertyValue(enumValue)
public void AddEnumerationPropertyValue(
    string enumValue
)
public:
void AddEnumerationPropertyValue(
    String^ enumValue
)
public function AddEnumerationPropertyValue(
    enumValue : String
)

Parameters

Exceptions

Exception Condition
ValidationException

The enumValue is invalid.

ArgumentNullException

The enumValue is nullNothingnullptra null reference (Nothing in Visual Basic).

EntityDoesNotExistException

The property does not exist.

EntityAlreadyExistsException

The enumValue already exists.

Remarks

You can use this method to add an enumeration value to a property of the Enumeration datatype. If specified,

The language should:

  • Not be null or blank.

  • Not exceed 10 characters.

  • Not contain the ,'[] characters.

  • Be specified for multilingual properties only.

Any new enumeration values added to the property will be saved to the catalog system only when the Save method is called.

Permissions

See Also

Reference

CatalogEnumerationProperty Class

CatalogEnumerationProperty Members

AddEnumerationPropertyValue Overload

Microsoft.CommerceServer.Catalog Namespace