posted value missing in dynamically created control

A

Andy Fish

Hi,

I have a web user control that has a textbox on it. In the form_load event
of the owning form, I dynamically add the web user control to the page.

The Load event of the control fires OK, but the value of the text field is
empty. Later on (say in a "click" event handler for the control) the value
is there OK.

From what I understand, if I loaded the control in the init event of the
owning form, the form's load event would be called after the posted values
were substituted so I would be OK. Unfortunately, I can't do that because
the decision of whether and where to put the control requires other values
on the owning form that aren't available until page load time.

Is there any event that I can hook into (or method I can override) that will
allow me to inspect the textbox value after the control is completely loaded
but before processing any click events?

TIA

Andy
 

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,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top