TimHudspith
asked on
Exception occurs launching .exe but no problem in IDE
I've created an application in VB.Net consisting of a couple of forms with listboxes and listviews showing lists of procedures and tables in a database. It works fine in debug mode in Visual Studio - I get no exceptions. But when I compile it and open the .exe it throws an exception when the second form opens, saying one of the parameter values is incorrect.
I have a line of code referencing the fifth subitem of a listitem in a listview:
The error message is "InvalidArgument=Value of '5' is not valid for 'index'". But there are 5 subitems in the listview so what's wrong with it?
I have a line of code referencing the fifth subitem of a listitem in a listview:
.SubItems(5).Text = vbNullString
The error message is "InvalidArgument=Value of '5' is not valid for 'index'". But there are 5 subitems in the listview so what's wrong with it?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Still wondering why the debugger passed over it.