I found a way to figure it out. I created a session variable flag, which I turn on when an event of a control inside my user control is triggered. on PreRender I check its state and turn it off.
Figuring out if an UpdatePanel was triggered from within or without
-
03-10-2022 - |
Frage
I have a user control that includes an updatepanel. That contorl is placed inside an updatepanel on the webpage. Is there a way to determine in the user control, if the postback was triggered by a contorl inside it or by a control on the page?
Lösung 2
Andere Tipps
You could place a label within the update panel and if the control triggers (if it's a button, on button click change the label text) then you can have the label change when the control is tiggered.
Hope that helps.
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow