Skip to Content
author's profile photo Former Member
Former Member

Error Code -5002 when updating Sales Quotation

Our Sales Quotation documents have 3 UDF: Contract Status, Approver1, Approver2.

when a user updates the Sales Quotation in SAP, our addon resets these fields by DI to 'Pending', "", "" , so the document needs to be approved again.

Here is the code called in AfterDataFormUpdate:

Me.oDoc.UserFields.Fields.Item("U_XX_Ap1U").Value = ""

Me.oDoc.UserFields.Fields.Item("U_XX_Ap2U").Value = ""

Me.oDoc.UserFields.Fields.Item("U_XX_ConSta").Value = "P"

fncRetVal.retCode = Me.oDoc.Update()

If fncRetVal.retCode <> AddonVars.enumReturnCodes.Success Then

oDiCompany.GetLastError(lErrCode, sErrMsg)

End If

I'm getting a retCode = -5002, and ErrMsg = "Cannot insert value in the 'Folio Number' field "

Has anyone seen this before? Any input is appreciated.

thanks,

Grace

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Best Answer
    Posted on Jan 10, 2008 at 09:26 AM

    i read once in another thread about this.

    its an sap bug in sap 2007.

    [error-documents-obj--5002cannot-insert-value-in-th|error-documents-obj--5002cannot-insert-value-in-th]

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.