Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 9190

Stock adjustment

$
0
0

Hello,

 

Using SAP 9.0 PL7

 

I am converting transaction history from another ERP to SBO 9.0 PL7.

 

I have come across a stock adjustment transaction type that can change either/both cost or quantity for a particular stock item.

 

In the SBO client I can see that Inventory->Inventory Transactions->Inventory Revaluation allows changing the cost for a particular item/warehouse (and revalues all the inventory in that warehouse accordingly).

 

Is there a way to change just the quantity via the client?

 

Can the following code snippet from Stock Revaluation By SDK be used to alter both cost & quantity?

 

 

  Dim MatrialRevaluation As SAPbobsCOM.MaterialRevaluation

        MatrialRevaluation = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oMaterialRevaluation)

       MatrialRevaluation.Lines.ItemCode = "CR001-001"

        MatrialRevaluation.Lines.RevaluationDecrementAccount = "R00071"

        MatrialRevaluation.Lines.RevaluationIncrementAccount = "R00071"

        MatrialRevaluation.Lines.WarehouseCode = "DEL"

        MatrialRevaluation.Lines.Price = 2000

        MatrialRevaluation.Lines.Quantity = 10

        MatrialRevaluation.Lines.Add()

 

        lRetCode = MatrialRevaluation.Add()

 

             If lRetCode <> 0 Then ' If the addition failed

            oCompany.GetLastError(lErrCode, sErrMsg)

            MsgBox(lErrCode & " " & sErrMsg) ' Display error message

        Else

            cmdInvoice.Enabled = True

            MsgBox("Entry successful")

        End If

 

Cheers!


Viewing all articles
Browse latest Browse all 9190

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>