Thanks.
I have my column names stored in web.config as key/value pairs.
column names might be added or removed from web.config files.
I would appreciate it, if you can show me a small eg. on how to acheive this
?
"Peter Bromberg [C# MVP]" <pb*******@yahoo.nospammin.com> wrote in message
news:BD**********************************@microsof t.com...
You could create an enum that maps the column names to ordinal position.
Peter
--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com
"gane" wrote:
Hi,
I would like to assign a value to a datagrid item using the column name
instead of using something like e.item.cell[1].text in itemdatabound
eg:
DataRowView rv = (DataRowView)e.Item.DataItem;
string strLocation = Convert.ToString(rv.Row["locationptr"].ToString())
I used dataitem to fetch, but i donno how to assign some value.
Thanks
Gane