다음을 통해 공유


Add Method (String, Object)

Add a Commerce.IDictionary object containing targeting properties to the end of the TargetingProfileCollection.

Namespace:  Microsoft.CommerceServer.Runtime.Targeting
Assembly:  Microsoft.CommerceServer.Runtime (in Microsoft.CommerceServer.Runtime.dll)

Syntax

'Declaration
Public Sub Add ( _
    name As String, _
    dictionary As Object _
)
'Usage
Dim instance As TargetingProfileCollection
Dim name As String
Dim dictionary As Object

instance.Add(name, dictionary)
public void Add(
    string name,
    Object dictionary
)
public:
void Add(
    String^ name, 
    Object^ dictionary
)
public function Add(
    name : String, 
    dictionary : Object
)

Parameters

  • name
    Type: System..::.String
    Name of the profile. This must match the profile identifier portion of any expressions that are to evaluate against the profile. May not be nullNothingnullptra null reference (Nothing in Visual Basic).
  • dictionary
    Type: System..::.Object
    Dictionary object to add. May not be nullNothingnullptra null reference (Nothing in Visual Basic).

Exceptions

Exception Condition
ArgumentNullException

One of the required parameter values was nullNothingnullptra null reference (Nothing in Visual Basic).

ArgumentException

dictionary is not a valid commerce dictionary.

Remarks

Adds a Commerce.IDictionary to the TargetingProfileCollection collection object. The Commerce.IDictionary object is added to the end of the TargetingProfileCollection. The Count of the collection is incremented.

Permissions

See Also

Reference

TargetingProfileCollection Class

TargetingProfileCollection Members

Add Overload

Microsoft.CommerceServer.Runtime.Targeting Namespace