static public string [] SplitString(string str,string separator){ string tmp = str; Hashtable ht = new Hashtable(); int i = 0; int pos = tmp.IndexOf(separator); while(pos != -1) { ht.Add(i,tmp.Substring(0,pos)); tmp = tmp.Substring(pos+separator.Length); pos = tmp.IndexOf(separator); i++; } ht.Add(i,tmp); string [] array = new string[ht.Count]; for(int j=0;j<ht.Count;j++) array[j] = ht[j].ToString(); return array;}