This is a migrated thread and some comments may be shown as answers.

DataItemIndex throws System.NotImplementedException

3 Answers 127 Views
ListView
This is a migrated thread and some comments may be shown as answers.
Steve
Top achievements
Rank 1
Steve asked on 17 Feb 2010, 06:11 PM
I'm using Telerik version 2009.3.1314.35.  I'm binding a RadListView control to a List of custom objects using .DataSource and .DataBind().  On submit, when I try to get the key values using item.DataItemIndex it throws a NotImplementedException and the item.DataItem object is null.  The strange thing is that the DataKeyValues array is fine and I can get the key value using item.DisplayIndex.  Any ideas why I would get this error?

3 Answers, 1 is accepted

Sort by
0
Rosen
Telerik team
answered on 18 Feb 2010, 01:42 PM
Hello Steve,

Indeed, as the exception implies the DataItemIndex property, you are trying to access is not implemented. You should use DisplayIndex instead.

Greetings,
Rosen
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Angie
Top achievements
Rank 1
answered on 28 May 2010, 06:39 PM
The problem with using DisplayIndex is that it does not take into account what page you are on if the listview is paged.  It would be helpful if this property were implemented.
0
Rosen
Telerik team
answered on 31 May 2010, 03:40 PM
Hi Angie,

Indeed we have added implementation for the property in question. You may download next internal build and try it out.

Regards,
Rosen
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Tags
ListView
Asked by
Steve
Top achievements
Rank 1
Answers by
Rosen
Telerik team
Angie
Top achievements
Rank 1
Share this question
or