cancel
Showing results for 
Search instead for 
Did you mean: 

Manual Reconciliation Object

Former Member
0 Kudos

Hi All,

I want to automate the Manual Reconciliation process.

Is there some kind of DI Object that I can use to Save\Reconcile  ?

Or do I need to use the screen ?

Kind Regards,

Brenden Draper

Accepted Solutions (0)

Answers (1)

Answers (1)

pedro_magueija
Active Contributor
0 Kudos

Hi Brenden,

Try the ExternalReconciliationsService.


//Get business service.

SAPbobsCOM.CompanyService oCompanyService = Cmpy.GetCompanyService();

SAPbobsCOM.ExternalReconciliationsService ExtReconSvc = 
                        (SAPbobsCOM.ExternalReconciliationsService)oCompanyService.GetBusinessService
(SAPbobsCOM.ServiceTypes.ExternalReconciliationsService);

SAPbobsCOM.ExternalReconciliation ExtReconciliation = 
                        (SAPbobsCOM.ExternalReconciliation)ExtReconSvc.GetDataInterface(SAPbobsCOM.ExternalReconciliationsServiceDataInterfaces.ersExternalReconciliations);

ExtReconciliation.ReconciliationAccountType = SAPbobsCOM.ReconciliationAccountTypeEnum.rat_BusinessPartner; // default is GL Account

//Reconcile object.
SAPbobsCOM. ReconciliationJournalEntryLine jeLine1 = (SAPbobsCOM. ReconciliationJournalEntryLine)ExtReconciliation.ReconciliationJournalEntryLines.Add();
jeLine1.TransactionNumber = "1";
jeLine1.LineNumber = 1;
                   
SAPbobsCOM.ReconciliationJournalEntryLine jeLine2 = (SAPbobsCOM. ReconciliationJournalEntryLine)ExtReconciliation.ReconciliationJournalEntryLines.Add();                 
jeLine2.TransactionNumber = "2";
jeLine2.LineNumber = 2;
                   
SAPbobsCOM.ReconciliationBankStatementLine bstLine1 = (SAPbobsCOM. ReconciliationBankStatementLine)ExtReconciliation. ReconciliationBankStatementLines.Add();
bstLine1.BankStatementAccountCode = "C1";
bstLine1.Sequence = 1;

SAPbobsCOM. ReconciliationBankStatementLine bstLine2 = (SAPbobsCOM. ReconciliationBankStatementLine)ExtReconciliation. ReconciliationBankStatementLines.Add();
bstLine2.BankStatementAccountCode = " C1";
bstLine2.Sequence = 2;

ExtReconSvc.Reconcile(ExtReconciliation); 

//Get object.
SAPbobsCOM.ExternalReconciliationParams ExtReconParam =
                        (SAPbobsCOM.ExternalReconciliationParams)ExtReconSvc.GetDataInterface(SAPbobsCOM.ExternalReconciliationsServiceDataInterfaces.ersExternalReconciliationParams);
ExtReconParam.AccountCode = "100012";
ExtReconParam.ReconciliationNo = "2";
ExtReconciliation = ExtReconSvc.GetReconciliation(ExtReconParam);

//Get Reconcile List.
SAPbobsCOM.ExternalReconciliationsParamsCollection ExtReconsParamsCollection = (SAPbobsCOM. ExternalReconciliationsParamsCollection)ExtReconSvc.GetDataInterface(SAPbobsCOM.ExternalReconciliationsServiceDataInterfaces.ersExternalReconciliationsParamsCollection);
                   
SAPbobsCOM.ExternalReconciliationFilterParams ExtReconFilteredParams =
                        (SAPbobsCOM.ExternalReconciliationFilterParams)ExtReconSvc.GetDataInterface(SAPbobsCOM.ExternalReconciliationsServiceDataInterfaces.ersExternalReconciliationFilterParams);
ExtReconFilteredParams.ReconciliationAccountType = SAPbobsCOM.ReconciliationAccountTypeEnum.rat_GLAccount;//"G/L Account"
ExtReconFilteredParams.AccountCodeFrom = "11200000-01-001-01";
ExtReconFilteredParams.AccountCodeTo = "12400000-01-001-01";
ExtReconFilteredParams.ReconciliationDateFrom = "05/03/11";
ExtReconFilteredParams.ReconciliationDateTo = "06/03/11";
ExtReconFilteredParams.ReconciliationNoFrom = 1;
ExtReconFilteredParams.ReconciliationNoTo = 2;
ExtReconsParamsCollection = ExtReconSvc.GetReconciliationList(ExtReconFilteredParams);

//Cancel reconciliations.
foreach (SAPbobsCOM.ExternalReconciliationParams ExtReconParam in ExtReconsParamsCollection)
{
            ExtReconSvc.CancelReconciliation(ExtReconParam);
  }


The above is form the SDK Help Center.



Best regards,

Pedro Magueija


View Pedro Magueija's profile on LinkedIn

Former Member
0 Kudos

Hi Pedro,

The better explanation would be:

Because I do not pull in the values into OBNK I cannot use the External Recon and there fore I must use the Manual Recon which does not have a object.

So I will rather pull in the Statement into the OBNK table so I do not have to use the manual Recon.

Does the a OBNK object exist to pull in the Bank Statement values ?

Kind Regards,

Brenden Draper