I am sending a ArrayList as below from a web service call :
private ArrayList testList = new ArrayList();
Which will store values like :
"xyz (pound) (4545)"
"abc (in) (346)"
"def (off) (42424)"
I use this because of two reasons :
1 : I have to fetch this value in ASP.NET 1.1 framework.
2 : I use testList.Sort(); before sending.
But now I want to send these values as :
"xyz" "pound" "4545"
"abc" "in" "346"
"def" "off" "42424"
So I found a way as below :
string[][] data = { new string[]{"xyz", "pound", "4545"},
new string[]{"abc", "in", "346"},
new string[]{"def", "off", "42424"}};
Question is : How can I sort it effectively?? OR Is there a better way to address this ?
Sort will be done based on first element :
abc
def
xyz