Home
> Uncategorized > Iterating products from sage
Iterating products from sage
I was working on a bit of code to iterate through all products stored within sage, eventually found it (code in VB.NET)
Dim SDO As New SageDataObject90.SDOEngine
Dim wsStock As SageDataObject90.WorkSpace
Dim srStock As SageDataObject90.StockRecord
Dim i As Short
Dim strDescription As String
Dim strStockCode As String
wsStock = SDO.Workspaces.Add("Myconnection")
wsStock.Connect(SageLocation, SageUsername, SagePassword, "ThisIsUnique")
srStock = wsStock.CreateObject("StockRecord")
srStock.MoveFirst()
DostrDescription = srStock.Fields.Item("DESCRIPTION").Value
strStockCode = srStock.Fields.Item("STOCK_CODE").Value
srStock.MoveNext()
Loop Until srStock.IsEOFwsStock.Disconnect()
Categories: Uncategorized
Comments (0)
Trackbacks (0)
Leave a comment
Trackback