Editing A Line In A Datagrid

J

JimHeavey

Hello, I have a row in a Datagrid which has a value
already provided for a field. When the user clicks
the "edit" link for that row in the datagrid,
the "EditItemTemplate" binds that column to a dropdown
list which has all of the valid values. The problem is
that when the line is being editted, the value which as
already been selected is not "preselected" in the row.
How can I get that item to show as being selected?
 
G

George Durzi

You need to set it in the DataGridName_OnEditCommand event

You know which row is being edited by accessing the
DataGridName.EditItemIndex property.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top