I have a collection of objects. I can successfully loop through the collection, and print the value of any property by explicitly stating the property such as obj.ProductGID will print out the value of the current object's ProductGID property.
Looking for a way to print out the values without having to explicitly stating each one. The code below will print the names of the properties, but I don't know how to get the value.
Can anyone help?
Code:Dim prop As System.Reflection.PropertyInfo For Each prop In obj.GetType.GetProperties() Debug.Write(prop.Name & " ^^ ") Next prop Debug.WriteLine(vbCrLf)