ASP.NET: How To Convert An ArrayList To A String Array
Here’s a quick helper post for those looking to convert an ArrayList into a String array. I ran into this problem because I code in VB.NET and the C# code is different.
'if you have an ArrayList named data Dim str() As String = data.ToArray(GetType(String))
//if you have an ArrayList named “data”
string strings = (string)data.ToArray(typeof(string));Hope this helps!