Convert an ArrayList of strings to a string[] array
September 18, 2006 by bnma
To convert an ArrayList to an array of strings, simply do the following:
string[] stringArray = (string[])arrayList.ToArray(typeof(string));
Where arrayList is an ArrayList of strings and stringArray is an array of strings.