Binding two dimensional arraylist to GridView?

N

nomad

Hi,

I have a two dimensional arraylist below, which I am trying to bind to
a gridview. However, when I try and do this the gridview is being
populated with what looks like property values i.e. Count, IsReadOnly
etc. Any ideas how I can get it to bind to the gridview showing the
correct values?

Code below.

private ArrayList ProcessEnumType(Type t)
{

ArrayList arrList = new ArrayList();
ArrayList arrString = new ArrayList();
ArrayList arrValue = new ArrayList();
foreach (var enumVal in Enum.GetValues(t))
{
var name = Enum.Parse(t, enumVal.ToString());
arrValue.Add((int)name);
arrString.Add(enumVal.ToString());

}
arrList.Add(arrValue);
arrList.Add(arrString);


return arrList;

}

Appreciate the help.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,898
Latest member
BlairH7607

Latest Threads

Top