ListView

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am writing a program for Pocket PC 2002 using VB.NET 2003. On a window
form, i have a ListView control. When I add an item:
Me.lv_main.Items.Add(ListViewItem)
It works just fine. When I want to add a second item, an ArgumentException
is thrown at the line above. I cannot get more information on the exception.
Does anyone have a solution do this? Please help. Thank you in advance.
 
There's not enough code here to tell exactly what you are doing so I'll ask.

Is ListViewItem being isntantiated each time with a different value?

Gerry
 
Thank you Gerry.

I have actually solved the problem since posting the article.

It is exactly what you said.

Before, I used the same ListViewItem.

Now that:

ListViewItem = New System.Windows.Forms.ListViewItem

is executed every time, it works fine.

Thank you very much any way.
 
Guess I forgot to read the dates. My fault.

Glad you got it working though.

Gerry
 

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

Back
Top