J
James Cooke
..NET version 3.5
Visual studio 9.0.21022
Using C#
It appears as if the listview index is 1 based and not zero based.
Steps to reproduce:
Create a listview and allow it to be updated
Add the method to trap the click event of the UPDATE button on the edititem template
<asp:Button CommandName="Update" ID="UpdateButton" OnClick="UpdateButton_Click" runat="server" Text="Update"/>
protected void UpdateButton_Click ( object sender , EventArgs e )
{
//ListView1.EditItem at this point will be NULL. But not if you clciked on annt subsequent ones.
}
Run the app, and edit the first row
then click the UPDATE button, and your debugger will stop at the above mentioned event handler
ListView1.EditItem is null.
--
Visual studio 9.0.21022
Using C#
It appears as if the listview index is 1 based and not zero based.
Steps to reproduce:
Create a listview and allow it to be updated
Add the method to trap the click event of the UPDATE button on the edititem template
<asp:Button CommandName="Update" ID="UpdateButton" OnClick="UpdateButton_Click" runat="server" Text="Update"/>
protected void UpdateButton_Click ( object sender , EventArgs e )
{
//ListView1.EditItem at this point will be NULL. But not if you clciked on annt subsequent ones.
}
Run the app, and edit the first row
then click the UPDATE button, and your debugger will stop at the above mentioned event handler
ListView1.EditItem is null.
--