I get the above error for the following line of code.this.webdatagrid1.Behaviors.Selection.SelectedRows[i].Items[0].Value
I get the row count correctly, but I get a system.nullreferenceexception. I know for a fact that the values are not null.
Help me Infragistics gurus!!
Hi ashwinnayak86,
Which object is null? The selected row that is returned? Do you have EnableCrossPageSelection on? If that is the case and the selected row is not always returned if we cannot find a row in the Rows collection that matches the data key we have stored at that index. Which event was this happening in?
regards,David Young
public
{
rowcount =
Convert.ToInt32(this.WebDataGrid1.Behaviors.Selection.SelectedRows.Count);
selectedtools[i] =
Convert.ToInt32(this.WebDataGrid1.Behaviors.Selection.SelectedRows[i].Items[0].Value);
{sesstools = sesstools + selectedtools[i];
}
else
sesstools = sesstools + selectedtools[i] +
", ";