Carl3003
asked on
How do you copy objects from one placeholder into another..
In my sample i wanted to create another placeholder with the same objects in it and place it in a different part of the page but for some reasons i could not just say phMyLinks=phMyLinks2 . I also tried to populate both placeholders at run time but it was populating only one of them. One way was to explicitely create another LinkButton and to make all actions parallel to both placeholders. I am looking to find an easier solution whereas i could populate both placeholders altogether .
Thanks
Label lblPage=new Label();
lblPage.Text="Page : ";
this.phMyLinks.Controls.Ad d(lblPage) ;
for(int i=1;i<=pageTotal;i++)
{
myLink=new LinkButton();
myLink.Text=" " + Convert.ToString(i) + " ";
myLink.Click+=new EventHandler(myLink_Click) ;
phMyLinks.Controls.Add(myL ink); //this becomes empty
phMyLinks1.Controls.Add(my Link);
}
Thanks
Label lblPage=new Label();
lblPage.Text="Page : ";
this.phMyLinks.Controls.Ad
for(int i=1;i<=pageTotal;i++)
{
myLink=new LinkButton();
myLink.Text=" " + Convert.ToString(i) + " ";
myLink.Click+=new EventHandler(myLink_Click)
phMyLinks.Controls.Add(myL
phMyLinks1.Controls.Add(my
}
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.