Dynamic Controls

D

danielhamd

Hello -

I am having some trouble with dynamic controls in Asp.Net. I have a
form for a user to enter certain information. When this information
is posted back, it is shown on the page by creating dynamic labels in
a table, and also putting a dynamic link button "remove" for each
entry.

I create the controls in the Page_Load function, so that I can wire up
the remove linkbutton to have a command event (that passes the index
of the data to be removed in a List that I store in the ViewState).
However, when the user removes, it renders the controls before it
removes the data, so although the data has been removed, it still
shows up until another postback or refresh is done.

Does anyone have any suggestions on how I can rewrite the series of
events or work around this particular problem?

Thanks,
Daniel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,059
Latest member
cryptoseoagencies

Latest Threads

Top