on 01-03-2014 10:44 AM
Hi
I want to update batch status using SDK
can anyone help which object or how can I update batch status using my add-on?
Nilehs Shah
Hi,
This can be done using the BatchNumberDetail in conjuction with the BatchNumberService objects.
Here is a sample code:
SAPbobsCOM.CompanyService oCompanyService ;
String docentry = 1; //Put here the actual AbsEntry of the Batchnumber record
oCompanyService = oCompany.GetCompanyService();
SAPbobsCOM.BatchNumberDetailsService oBatchNumbersService ;
oBatchNumbersService = oCompanyService.GetBusinessService(SAPbobsCOM.ServiceTypes.BatchNumberDetailsService);
SAPbobsCOM.BatchNumberDetailParams oBatchNumberDetailParams;
oBatchNumberDetailParams = oBatchNumbersService.GetDataInterface(SAPbobsCOM.BatchNumberDetailsServiceDataInterfaces.sndsBatchNumberDetailParams);
oBatchNumberDetailParams.DocEntry = docentry;
SAPbobsCOM.BatchNumberDetail oBatchNumberDetail ;
oBatchNumberDetail = oBatchNumbersService.Get(oBatchNumberDetailParams);
oBatchNumberDetail.Status = BoDefaultBatchStatus.dbs_Locked; //put here the status you want
oBatchNumbersService.Update(oBatchNumberDetail);
Beni.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
7 | |
6 | |
4 | |
3 | |
3 | |
3 | |
3 | |
3 | |
2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.