P
plork
hi all i have a method that takes an array
e.g. public void Method (string [] array)
the contents of array are somthing like below, i don't know what the
length will be be until i do a array.Length
a snippet of results is
id title description
0] = "1000", "aaa", "some text"
[1] = "1000", "bbb", "some text"
[2] = "1000", "ccc", "some text"
[3] = "2000", "ddd", "some text"
[4] = "2000", "eee", "some text"
[5] = "3000", "fff", "some text"
[6] = "3000", "ggg", "some text"
[7] = "3000", "hhh", "some text"
[8] = "4000", "iii", "some text"
[9] = "5000", "jjj", "some text"
[10] = "6000", "kkk", "some text"
If i do this for (int i = 0; i < array.Length; i++)
i can see the length of the whole array
But is anyone able to show me how i get the length of id? e.g. I want
to see how many results have an id of e.g. 1000 or id of 2000
etc ....and then loop through those results
e.g. public void Method (string [] array)
the contents of array are somthing like below, i don't know what the
length will be be until i do a array.Length
a snippet of results is
id title description
0] = "1000", "aaa", "some text"
[1] = "1000", "bbb", "some text"
[2] = "1000", "ccc", "some text"
[3] = "2000", "ddd", "some text"
[4] = "2000", "eee", "some text"
[5] = "3000", "fff", "some text"
[6] = "3000", "ggg", "some text"
[7] = "3000", "hhh", "some text"
[8] = "4000", "iii", "some text"
[9] = "5000", "jjj", "some text"
[10] = "6000", "kkk", "some text"
If i do this for (int i = 0; i < array.Length; i++)
i can see the length of the whole array
But is anyone able to show me how i get the length of id? e.g. I want
to see how many results have an id of e.g. 1000 or id of 2000
etc ....and then loop through those results