Delete Method
Deletes an existing Customer record.
Namespace: Microsoft.CommerceServer.Marketing
Assembly: Microsoft.CommerceServer.Marketing.CrossTierTypes (in Microsoft.CommerceServer.Marketing.CrossTierTypes.dll)
Syntax
'Declaration
Public Sub Delete ( _
customerId As Integer _
)
'Usage
Dim instance As CustomerManager
Dim customerId As Integer
instance.Delete(customerId)
public void Delete(
int customerId
)
public:
void Delete(
int customerId
)
public function Delete(
customerId : int
)
Parameters
- customerId
Type: System..::.Int32
The Id of the Customer to delete. May not be less than 1.
Exceptions
Exception | Condition |
---|---|
ArgumentOutOfRangeException | customerId is less than 1. |
EntityDoesNotExistException | The requested Customer record does not exist. |
EntityHasChildrenException | The requested Customer record cannot be deleted because it contains Campaign objects. |
EntityStateException | The Customer record is already deleted or Customer contains active Campaign objects. |
Remarks
Deleting a Customer does not actually remove the customer record from the database. These records are not permanently removed until the PurgeDeletedCustomers method is called to purge them from the database.
Permissions
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.