No one has any idea?  how do i refresh the main webform after closing
a modal popup extender from a User Control?

If that's not possible, what's the usual way you guys code generic
dialogs that can be used easily in many web forms?

thanks!!

On Mar 13, 10:29 am, Ben <[email protected]> wrote:
> In ASP.net C#, i'm trying to make a logon window i can easily use in
> many pages.
>
> So I added a user control that has the username/pwd fields and
> 'cancel' / 'logon' buttons.  The code-behind of the 'logon' button
> uses DirectoryServices to auth.  If it fails, it just updates a label
> with an error... if it succeeds I call a 'LogonDialogClosed()' method
> on the parent page (using events/delegates) and then close the
> modalpopupextender by using FindControl to locate the extender on the
> parent, like so:
>
>             eventAuthenticated.DynamicInvoke();
>             ModalPopupExtender mpeParentPopupExtender =
> (ModalPopupExtender)this.Parent.FindControl("ModalPopupExtender_" +
> this.ClientID);
>             mpeParentPopupExtender.Hide();
>
> It ALMOST works perfect.  Popup opens fine... on auth error it
> updates
> the label (with no refresh to main page) and popup stays in place...
> on successful auth, it calls the parent webform LogonDialogClosed
> function and if i debug i can see i get there... however, if i try to
> update a control on the page it doesn't show (for example, update a
> textbox).  What i really want to do is take some action and reload a
> gridview.  I do have an UpdatePanel in the main form, and if i call
> it's Update method the page refreshes, but then the modal background
> stays and i can't click on anything.... why would that cause the Hide
> method to fail?!?  If i change the order i call things above it
> doesn't help...
>
> thanks for any advice!!

Reply via email to