2
Answers

Listview with many rows

bartek bartek

bartek bartek

15y
5k
1

I have a small application in C# with data from Access.

I used listview and it's work ........ standard table in Access have about 10000 rows. Listview load  all rows with data about 30 seconds.

but when it's 100000 the listview don't work. Application load data over 15 minuts using 80% procesor

this my code ........... Where is the problem ??? . I don,t want used DataGrid ....... Listview looks better.

         while (reader.Read() == true)
            {
                lvItem = listView1.Items.Add(reader.GetValue(0).ToString());

                for (int i = 1; i < nCount; i++)
                {
                    lvItem.SubItems.Add(reader.GetValue(i).ToString());
                }
            }

 

Thanks :)

 

Sorry for my English :)

Answers (2)