Subhash Sharma

Subhash Sharma
Subhash Sharma

This is Subhash Sharma(Software Engineer) Blog

Welcome to this blog and find every solution.............

Search This Blog

Software Engineer(Subhash Sharma)

Software Engineer(Subhash Sharma)
Software Engineer
Showing posts with label Fetch Value Through UserControl (.ascx file). Show all posts
Showing posts with label Fetch Value Through UserControl (.ascx file). Show all posts

Wednesday, July 28, 2010

Fetch Value Through UserControl (.ascx file)

//ADC is a user controlName wich we will add in @response directive

//Ex:(Inline Code) %@ Register TagName ="ABC" TagPrefix ="ABC" Src="~/WebUserControl.ascx"%>
after that you can add where u want......
ABC:ABC ID="ADC" runat="server" />

.cs (Code Behind)

WebUserControl we;
we = (WebUserControl)this.FindControl("ADC");
TextBox txtuser = (TextBox)we.FindControl("txtname");
TextBox txtpassword = (TextBox)we.FindControl("txtPassword");