📚 SAP Business One SDK Help

DeleteDunningTerm Method
See Also  Example
pIDunningTermParams
The key of the dunning term to be deleted.

Description

Deletes an existing dunning term.

The dunning term is specified by its key (TermCode), which is contained in the DunningTermParams object passed to the method.

Syntax

Visual Basic
Public Sub DeleteDunningTerm( _
   ByVal pIDunningTermParams As DunningTermParams _
) 

Parameters

pIDunningTermParams
The key of the dunning term to be deleted.

Example

Deleting a dunning term (C#)Copy Code
SAPbobsCOM.DunningTermsService dts = globals_Renamed.oCompany.GetCompanyService().GetBusinessService(ServiceTypes.DunningTermsService) as DunningTermsService; 
SAPbobsCOM.DunningTermParams dtp = dts.GetDataInterface(DunningTermsServiceDataInterfaces.dtsDunningTermParams) as DunningTermParams; 
dtp.Code = "Code5327"; 
 
try 

    dts.DeleteDunningTerm(dtp); 

catch (Exception ex) 

    MessageBox.Show(ex.Message); 

See Also