Skip to Content
0

Link documents to service call - Now related to record found

Feb 14 at 06:54 AM

23

avatar image
Former Member

Hi, I have written some code that links sales documents to service calls. However, in many cases I get the error:

10000677 - No related record found

below is my code:

Can somebody please help?

SAPbobsCOM.ServiceCalls oService = (SAPbobsCOM.ServiceCalls)globals.oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oServiceCalls);

if (oService.Expenses.DocEntry != 0)                        
    {
      oService.Expenses.Add();
    }
 oService.Expenses.DocEntry = int.Parse(docNum);

oService.Expenses.DocumentType = SAPbobsCOM.BoSvcEpxDocTypes.edt_Delivery;
                            
if (oService.Update() != 0)
{
globals.SBO_Application.MessageBox(globals.oCompany.GetLastErrorDescription(), 1, "OK", "", "");
}
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

0 Answers