|
-
Jul 8th, 2003, 09:15 AM
#1
Thread Starter
Lively Member
twice same usercontrol on 1 page
Hello everybody,
I'm trying to load twice the same usercontrol on my webpage with this code :
VB Code:
Dim myCtl1 As Colli = Page.LoadControl("colli.ascx")
Dim myCtl2 As Colli = Page.LoadControl("colli.ascx")
'Controls.Add(myCtl1)
PlaceHolder1.Controls.Add(myCtl1)
PlaceHolder2.Controls.Add(myCtl2)
It only appears once My placeholder 2 is much lower on my page, so they aren't on top of each other.
Anyone has ideas if this is possible ?
Thanks,
Bjorn
-
Jul 8th, 2003, 09:38 AM
#2
PowerPoster
Works for me:
Make sure visible is set to true for the placeholder.
Code:
private void Page_Load(object sender, System.EventArgs e)
{
PlaceHolder1.Controls.Add(LoadControl("CurrentTimeStamp.ascx"));
PlaceHolder2.Controls.Add(LoadControl("CurrentTimeStamp.ascx"));
}
-
Jul 9th, 2003, 03:04 AM
#3
Thread Starter
Lively Member
Hi Lethal,
I already know the reason ... It was because of the dhtml.
My two panels where exactly placed on top of each other. I saw it in my source code !
Thanks !
Bjorn
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|