Share via


DeleteCampaign Method

Deletes an existing Campaign.

Namespace:  Microsoft.CommerceServer.Marketing.WebService
Assembly:  Microsoft.CommerceServer.Marketing.DataManagement (in Microsoft.CommerceServer.Marketing.DataManagement.dll)

Syntax

'Declaration
<WebMethodAttribute> _
Public Overridable Sub DeleteCampaign ( _
    campaignId As Integer _
)
'Usage
Dim instance As MarketingWebService
Dim campaignId As Integer

instance.DeleteCampaign(campaignId)
[WebMethodAttribute]
public virtual void DeleteCampaign(
    int campaignId
)
[WebMethodAttribute]
public:
virtual void DeleteCampaign(
    int campaignId
)
public function DeleteCampaign(
    campaignId : int
)

Parameters

  • campaignId
    Type: System..::.Int32
    The identifier of the Campaign to be deleted.

Exceptions

Exception Condition
NotAuthorizedException

The user is not authorized to perform the requested operation.

ArgumentOutOfRangeException

campaignId is less than zero.

EntityHasChildrenException

The entity has children.

EntityStateException

The entity is in an invalid state (may already be deleted).

EntityDoesNotExistException

No campaign exists with this Id campaignId.

DatabaseIntegrityException

An integrity issue with the database exists.

Remarks

Deletes an existing Campaign.

Deleting a Campaign does not actually remove the campaign record from the database. These records are not permanently removed until they are purged from the database. Deleting a Campaign will also delete all campaign items associated with the Campaign. Deleting a Campaign will remove the campaign-to-customer association.

Permissions

See Also

Reference

MarketingWebService Class

MarketingWebService Members

Microsoft.CommerceServer.Marketing.WebService Namespace