Question asked by one of interviewer in panal is given
below:
We have 2 user control on same page ,1st user control
contains textbox and a button while 2nd user control have
label.
when ever we click on button click of 1st custom control
button the value of the textBox will get updated into Label
of 2nd custom control.

How to do this.Your help will be appreciated.



Question asked by one of interviewer in panal is given below: We have 2 user control on same page..

Answer / magesh

ControlA ctrlA =
(ControlA)Page.FindControl("<usercontrolname>");
TextBox textBoxA=(TextBox)ctrlA.FindControl("<Textbox name>");

ControlB ctrlB =
(ControlB)Page.FindControl("<usercontrolname>");
Label labelB=(Label )ctrlB.FindControl("<Textbox name>");
Label.Text=TextBox.Text;

Is This Answer Correct ?    9 Yes 1 No

Post New Answer

More ASP.NET Interview Questions

how can i inharit multiple classes?

3 Answers  


When a dropdownlist has been added by some records and it has been binded why it is not executing i'm facing this error pls help me ? if (is!pageposback) { arraylist books = new arraylist; books.add ("gone with the wind"); books.add ("rahulsriramprakash"); books.add ("vishal"); dropdowndisplay.datasource=books; dropdowndisplay.databind(); } The error is : 1) The dropdowndisplay does not exist.

5 Answers   Netsweeper,


In try catch blocks one is normal catch block and another is sqlcatchexception block

3 Answers   Microsoft,


Can you explain one critical mapping? Performance issue which one is better? Whether connected lookup tranformation or unconnected one?

1 Answers  


What is the difference between page.registerclientscriptblock and page.registerstartupscript?

1 Answers  


How do you register JavaScript for webcontrols ?

1 Answers  


Why do we use asp.net?

1 Answers  


What is the difference between a default skin and a named skin?

1 Answers   MindCracker,


Tell About Web.config ?

2 Answers   Keane India Ltd,


What are runtime hosts?

4 Answers   Microsoft,


To call a Web service SOAP which transport protocol you use?

3 Answers   Siebel,


witch is the best insistute in sharpoint course.what abt future of share point course.

3 Answers  


Categories