Programmatically getting all products from all categories
Posted: Tue Apr 05, 2016 5:23 pm
Hi,
Recently upgraded to Gold and am unable to load all products from all categories. In the past, I used to be able to do this:
But now, this no longer works. What do I need to do to fix the above code?
Thank you.
Recently upgraded to Gold and am unable to load all products from all categories. In the past, I used to be able to do this:
Code: Select all
Function GetProducts() As ArrayList
Dim dataSource As ProductDataSource = New ProductDataSource()
Dim productCollection As ProductCollection = dataSource.LoadForStore()
Dim pArray As ArrayList = New ArrayList()
For Each product As Product In productCollection
pArray.Add(product.Name)
Next
Return pArray
End Function
Thank you.