C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !




adding dynamically textbox and labels in Windows applications


Posted Date: 25 Jul 2008      Total Responses: 3

Posted By: A.raghavender       Member Level: Gold     Points: 1


adding dynamically textbox and labels in Windows applications



Responses

Author: UltimateRengan    25 Jul 2008Member Level: DiamondRating:     Points: 1
Dim x As New TextBox
x = New TextBox
Me.Controls.Add(x)
Dim y As New Label
y.Text = "runtime"
Me.Controls.Add(y)



Author: Biju    26 Jul 2008Member Level: GoldRating:     Points: 4
hi,

As your question, you are not menstioning for using asp.net or Vb.net

using asp.net,

you can use the place holder control,

once you placed the place holder, then write the below code snipet

TextBox txtName = new TextBox();
txtName.Id = "txtName";


Regards
Biju S


Author: Sabu C Alex    28 Jul 2008Member Level: GoldRating:     Points: 6
hi

see this code


TextBox txt = new TextBox();
txt.Location = new Point(1, 1);
txt.Text = "Your Text";
this.Controls.Add(txt);

Label lbl = new Label();
lbl.Location = new Point(3, 3);
lbl.Text = "Name";
this.Controls.Add(lbl);


check ur forms Designer file. so that you can understand how framework creating controls.

if you are working with c#
file name id form.Designer.cs
if vb then

file name is form.Designer.vb



Post Reply
You must Sign In to post a response.
Next : help me out
Previous : what is E-R diagrams
Return to Discussion Forum
Post New Message
Category: Windows

Related Messages



dotNet Slackers   BizTalk Adaptors    Web Design

doors in nj

Contact Us    Privacy Policy    Terms Of Use