ArrayList list = new ArrayList();
list.Add("aaa");
list.Add("bbb");
//转换成数组
string[] arrString = (string[])list.ToArray(typeof( string));
ArrayList list = new ArrayList(new string[] { "aaa", "bbb" });
ArrayList list = new ArrayList();
list.Add("aaa");
list.Add("bbb");
//转换成数组
string str= string.Join(",", (string[])list.ToArray(typeof( string)));
string str="1,2,3,4,5";
ArrayList b = new ArrayList( str.Split(',') );
from:https://www.cnblogs.com/stone_w/archive/2012/03/21/2409357.html