TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Administrator
Tech Writer
2.2k
1.5m
Dynamic add UserControl problem
Mar 27 2003 4:18 PM
Hi all! I have a page which by default shows one instance of a UserControl. I also have a Button that has the following codebehind: int iCount = (int)Session["Count"]; iCount++; Session["Count"] = iCount; Control oControl = LoadControl("EmpRecord.ascx"); oControl.ID = "oEmpRecord" + iCount.ToString(); oDivRecords.Controls.Add(oControl); oControl = null; (note that Session["Count"] is set to 1 in Page_Load if NOT postback.) Ok, so I click the button and a new instance of the UserControl shows up at the screen!! Hurray! It works! But wait! I try again, and nothing happens. The page reloads, but nothing happens. Still just 2 UserControls there. WHAT IS WRONG??? It's driving me crazy!! Thanks.
Reply
Answers (
3
)
Validations using Javascript!
how to send multi part MIME email (text and HTML)