on 10-25-2023 10:45 AM
I want to apologize in advance If this post is already answered. Since I didn't find any related to this.
I can't find SAP object for the DI API of Inventory Transfer Request even from the SAP documentation. Im have this error DI error "Error: (-10) Internal error (-10) occurred" . Any recommendation or workaround for this? Thank you so much
Hi saintneo007,
Here is the complete code:
SAPbobsCOM.StockTransfer oST = (SAPbobsCOM.StockTransfer)oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oInventoryTransferRequest);
oST.Comments = "Created via DI";
oST.Lines.FromWarehouseCode = "01";
oST.Lines.WarehouseCode = "02";
oST.Lines.ItemCode = "A00001";
int AST = oST.Add();
Hope it helps!
Kind regards,
ANKIT CHAUHAN
SAP Business One Support
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ANKIT,
Thank you for this, I have a similar code and it works when I remove "oITR.Lines.UoMEntry". But, without this the default UOM is "pcs" the lowest UOM, I need to include the required UOM for a particular transaction. Is there any workaround that you can suggest or am I doing it in wrong way? Thank you so much.
@ankit.chauhan1
My code is something like this and still has the same error.
Dim oITR As SAPbobsCOM.StockTransfer
oITR = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oInventoryTransferRequest)
oITR.CardCode = "V000001"
oITR.FromWarehouse = "600"
oITR.ToWarehouse = "100"
oITR.DocDate = DateTime.Now.ToString("MM/dd/yyyy")
oITR.DueDate = DateTime.Now.ToString("MM/dd/yyyy")
oITR.TaxDate = DateTime.Now.ToString("MM/dd/yyyy")
oITR.Comments = "System Generated"
oITR.Lines.ItemCode = "111222333"
oITR.Lines.UoMEntry = "13"
oITR.Lines.UnitsOfMeasurment = 1
oITR.Lines.Quantity = 3
oITR.Lines.Price = "124.083333"
oITR.Lines.FromWarehouseCode = "600"
oITR.Lines.WarehouseCode = "100"
oITR.Add()
Hi @ankit.chauhan1,
Direct changing of UoM I think it's not possible, but it will change depending on the Barcode of the item going to be input manually.
Example on this item, if I use the itemcode and the default UoM will always be PCS in DI API, how will I make it to another UoM if the uomcode is read-only in Inventory Transfer Request. I'm working with the uomentry so I have the error "Error: (-10) Internal error (-10) occurred". Is there any other solution or workaround that you can suggest?
Thank you so much.
Hi saintneo007,
Check Object Type: 1250000001.
Hope it helps!
Kind regards,
ANKIT CHAUHAN
SAP Business One Support
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
97 | |
10 | |
8 | |
6 | |
3 | |
3 | |
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.