on 11-26-2009 5:01 PM
I get the above error when I update a quotation with the sdk.
The only fields I adjust are the price and unitprice fields.
This doesn't happen with all my quotations tho just with a few.
I can still manually update them in SAP but can't do any update of the quotation using the sdk.
When I duplicate the quotation the error remains.
Code:
Dim oDoc As SAPbobsCOM.Documents = Nothing
oDoc = sapCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oQuotations)
If oDoc.GetByKey(Docentry) = False Then Return False
oDoc.Lines.SetCurrentLine(mRs.Fields.Item("visorder").Value)
oDoc.Lines.Price = JoroFunctions.IsNull(mRs.Fields.Item("tot").Value, 0)
oDoc.Lines.UnitPrice = JoroFunctions.IsNull(mRs.Fields.Item("tot").Value, 0)
If oDoc.Update <> 0 Then
MessageBox.Show(sapCompany.GetLastErrorDescription)
end if
Any idea what might be causing this error?
Solved the problem
It was due to a y/n field being set to 1 for half the lines in the quotation.
Had to manually look it all up and found that field 'UseBaseUn' was set to 1 for the first half of the quotation
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello
This is a documented function, in between SAP Notes.
I mean the Price and UnitPrice field usage.....
See SAP Note: 1334050
Regards,
J.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Although it's an interesting read it doesn't solve my problem.
The only thing that could have been relevant is the text about "calculate the row total using the unit price" but I can't find this option anywhere.
I tested it now with only setting the unitprice and the error still remains.
Any other idea as to what might be causing this?
User | Count |
---|---|
95 | |
11 | |
11 | |
6 | |
6 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.