Is it possible to turn an object to an array in VB.net?
I have a object from outlook which is a mailitem, and I want to turn all the variables into an array to store in a file.
I know Ill loose the functionality of the object (such as move, copy etc) however i only want to store all the information in the object (in this case mailID, recipents etc).
Usually I could just count the elements and then copy the values one at a time, however the mailitem is a nested array inside a nested array inside a nested array so could be quite confusing.
yes, that's possible. you may want to consider to store it in a List(Of T) or look into the ToArray() method
List(Of T) Class
(look for the possible constructors and click on it to see the examples)
List<T>.ToArray Method ()