On Aug 31, 8:25*pm, "Chris Kennedy" <chris.kenned...@btinternet.com>
wrote:
Quote:
I am getting a generic list of objects from a webservice. The list is
converted to an array by this process. How do I convert the array back toa
list and is there any way of finding an object within the list via one it's
properties. I have seen it done in C# but not VB.
E.g. obj = get object from list where obj.id = 1. I could do some kind of
solution using loops but I was hoping for something a little more slick.
This is for .net 2.0 by the way. Regards, Chris.
Hi,
I don't know if it doesn't what you're looking for, but List type has
AddRange method to adds elements into List.
Imports System
Imports System.Collections.Generic
' Assuming you have an Integer array of IDs
Dim intArray() As Integer = {0,1,2,3....} ' goes on
Dim intList As New List(Of Integer)
intList.AddRange(intArray)
Hope this helps,
Onur Güzel