Lorna70
asked on
DetailsView - how to default to edit mode if record exists and Insert mode if it doesn't?
I have a DetailsView for Insert and Edits which I pass custID parameter by Querystring. I need the DetailsView to go into Edit mode if a record is returned for this customer from the db and if not, I need it to go into Insert mode. I'm using ASP.Net 2.0 - there must be an easy way to do this surely?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Hi,
Did you have a look at this?
/Carl.
Did you have a look at this?
/Carl.
ASKER
Yes thanks - that works (although I had to change it to C#).
http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.detailsview.defaultmode.aspx