views:

150

answers:

1

Hi

I have a control placed in edit item template in detail view control. what ever the control I am using I need to access those values in my code behind page that in my item updating event

Can any one tel me the syntax how to acces it those control values?

Actually what ever control are there in my edit item template are not added in my designer.cs file what is the issue for this

thank you

+1  A: 

this will definitly work try..

protected void DetailsView1_ItemUpdating(object sender, DetailsViewUpdateEventArgs e)
{
    TextBox txtbox = (TextBox)DetailsView1.FindControl("YourControlID");
}
Muhammad Akhtar
thank you Muhammad Akhtar it worked fine
prince23
you are welcome.......
Muhammad Akhtar