Listview DataRowView and ListViewDataItem

by rbellantoni 8/4/2010 5:01:00 AM

First you need to cast the listview item to a listviewdataitem, then you can cast it to a datarowview and pull out any information from the datasource like so

drv["Title"].ToString() 

 

CODE SNIPPET:

ListViewDataItem lvd = (ListViewDataItem)e.Item;

DataRowView drv = (DataRowView)lvd.DataItem;

Tags:

Powered by BlogEngine.NET 1.5.0.7
Theme by Mads Kristensen

About the author

Name of author Author name
Something about me and what I do.

E-mail me Send mail

Calendar

<<  October 2014  >>
MoTuWeThFrSaSu
293012345
6789101112
13141516171819
20212223242526
272829303112
3456789

View posts in large calendar

Recent comments

Tags

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2014

Sign in