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

what is asp and asp.net ?

2 Answers   Inspira Technologies,


what is CLR?

3 Answers   PrimeLine,


What is loop in asp.net?

0 Answers  


Finally and dispose methods?

1 Answers   Microsoft,


How can I create master page in asp net?

0 Answers  






How does a content page differ from a master page?

0 Answers  


How will you do Redo and Undo in a TextControl?

0 Answers  


Define satellite assemblies.

0 Answers  


What is Http handler?

5 Answers   Accenture,


What is Virtual path in ASP.Net

2 Answers   Proteans,


How can you ensure a permanent cookie?

0 Answers  


Why cyclomatic complexity is important?

0 Answers  


Categories