How can i load the text box and label at the runtime based
on the existing text box and tabel

Answers were Sorted based on User's Feedback



How can i load the text box and label at the runtime based on the existing text box and tabel..

Answer / anil

Generally code goes like this
private void LoadControl()
{
TextBox tb = new TextBox();
tb.Location = new Point(500, 100);
tb.Visible = true;
this.Controls.Add(tb);
}

Is This Answer Correct ?    3 Yes 0 No

How can i load the text box and label at the runtime based on the existing text box and tabel..

Answer / dhara

public void labelcontrol()
{
label l=new label();
l.visible=true;
l.location =new point(100,100);
l.text="Name";
this.controls.add(l);
}
FOR CREATING LABEL AT RUNTIME.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C Sharp Interview Questions

what is generics? can u explain 5 to 6 examples on generics that covers class,method,structure,list,delegates?

2 Answers   Satyam,


How to store image file in Sql server database?

4 Answers   Unique Software Systems,


what is software?

4 Answers   Cadsys, Zefer,


Why use a singleton instead of static methods?

0 Answers  


what is meant inheritance. can you exaplain what kind inhertance ussed in your project

1 Answers  






What does addressof operator do in background ?

0 Answers  


What are object pooling and connection pooling and difference between them?

0 Answers  


What is multicast delegate in c# ?

0 Answers  


how can i display crystal report in button_click? am working with VS2005..........plz help me

1 Answers  


What?s the advantage of using System.Text.StringBuilder over System.String?

3 Answers  


What is the difference between a field and a property in c#?

0 Answers  


Can abstract class have constructor in c#?

0 Answers  


Categories