Skip to Content
0
Former Member
Feb 03, 2009 at 04:51 PM

Problem with closing Goods Receipt PO

11 Views

Hello,

I want to close a Goods Receipt PO Document.

When I use the code below, an error occurs ( Date deviates from due date range,'208040' ) :

Public oGoodsRPO As SAPbobsCOM.Documents = CType(oComp.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oPurchaseDeliveryNotes), SAPbobsCOM.Documents)

oGoodsRPO.GetByKey(120210)

Dim Derr As Integer = oGoodsRPO.Close()

If Derr <> 0 Then

Dim serr As String = ""

oComp.GetLastError(Derr, serr)

Throw New Exception(serr)

Else

SBO_Application.SetStatusBarMessage("Goods Receipt was closed successfully")

End If

I then tried to change the active period and set it in October 2006, but

always the same problem.

What's the Origin of this problem and how I can solve it.

Thank You,

Best Regards,

Youssef El Bahmi.