Click here to Skip to main content
15,896,063 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
HI,
I need to display user control design in form at run time , using one form i need to load several usercontrol in run time , can any one help me soon for me running out time



thanks in advance!!


I am new to this task can any guide me with more details Plz!!

can any 1 help me soon due to i am in end!!!
Posted
Updated 27-Dec-11 23:11pm
v3

VB
For i=1 to 10
  Dim uc as New MyUserControl
  'set location and other required properties of user control
  Me.Controls.Add(uc)
Next
 
Share this answer
 
First create object of your User Control
VB
Dim MyControl As UserControl

After that add that control in your Form Controls
VB
Me.Controls.Add(Me.MyControl)
 
Share this answer
 
first reg that user control in form using
<%@ Register Src="controlname" TagName="" TagPrefix="" %>
next use that control where u want
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900