interviews.dotnetthread.com

↑ Grab this Headline Animator

Tuesday, July 15, 2008

How to convert an Array into an ArrayList?

Lets say you have array of Person object and you are getting an it from LoadPersons() method of your object like this

Person[] myPersonArray = myPerson.LoadPersons();

Now, if you want to convert above array into an ArrayList just write like this

ArrayList myPersonList = ArrayList.Adapter(myPersonArray );

Submit this story to DotNetKicks

No comments:

Post a Comment

Post your comments/questions/feedback for this Article.

 

Latest Articles