المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : Displaying the contents of a List in a ListBox



C# Programming
01-27-2010, 09:40 PM
Hello

I have an list array of strings that I would like to display in a list box.

List Param = new List();

if I do

for (int index = 0; index < Param.Count; index++)
{
listBox1.Items.Add(Param[index][0]+"\t"+Param[index][1]);
}

The output is all skewed depending on what the length of the first string is.

How can I make this a multicolumn listbox, writing each string to the appropiate colummn?

Thank you in advance.