📚 SAP Business One SDK Help

AddDeposit Method
See Also  Example
pIDeposit
The data for the new deposit.

Description

Adds a deposit.

Syntax

Visual Basic
Public Function AddDeposit( _
   ByVal pIDeposit As Deposit _
) As DepositParams

Parameters

pIDeposit
The data for the new deposit.

Example

Adding Deposit (C#)Copy Code
//Get company service 
CompanyService companyService = oCompany.GetCompanyService(); 
 
//Get deposit service 
SAPbobsCOM.DepositService dpService = (SAPbobsCOM.DepositService)companyService.GetBusinessService(ServiceTypes.DepositService); 
 
//Deposit with Cash 
SAPbobsCOM.Deposit dpsAddCash = (SAPbobsCOM.Deposit)dpService.GetDataInterface(DepositServiceDataInterfaces.dsDeposit); 
//Specify the deposit type 
dpsAddCash.DepositType = BoDepositTypeEnum.dtCash; 
//Set deposit currency type 
dpsAddCash.DepositCurrency = "RMB"; 
dpsAddCash.AllocationAccount = "100201"; 
dpsAddCash.DepositAccount = "100101"; 
dpsAddCash.TotalLC = 233.5; 
dpsAddCash.JournalRemarks = "Adding Deposit with Cash"; 
 
//Add the deposit 
SAPbobsCOM.DepositParams dpsParamAddCash = dpService.AddDeposit(dpsAddCash);

See Also