Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Modal Dialog

Reply
Thread Tools

Modal Dialog

 
 
=?Utf-8?B?RGF2ZXkgUA==?=
Guest
Posts: n/a
 
      06-15-2005
I am able to open a modal dialog on a button click from the code behind by
placing a RegisterClientScriptBlock() method in the button click event
handler. This all works fine, but the problem is that when the modal box is
displayed, the parent page in the background goes blank until the dialog has
closed and returned.
I have to do it this way as there is a lot of server side processing needed
to get the arguments to pass into the dialog args, otherwise I would do it
all client side using html buttons. Is there any way to get the parent to
postpone posting back until the modal has shut?

Thanks
 
Reply With Quote
 
 
 
 
Eliyahu Goldin
Guest
Posts: n/a
 
      06-15-2005
You call showModalDialog before the page has finished loading. That's why it
stays black. I suggest you to call showModalDialog in body's onload event.
This would be your scenario:
1. User clicks the button on the parent.
2. Server-side OnClick event calculates the parameters for the dialog and
puts them in hidden input controls.
3. Client-side onload event gets the parameters from the hidden inputs and
calls showModalDialog.

Eliyahu

"Davey P" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I am able to open a modal dialog on a button click from the code behind by
> placing a RegisterClientScriptBlock() method in the button click event
> handler. This all works fine, but the problem is that when the modal box

is
> displayed, the parent page in the background goes blank until the dialog

has
> closed and returned.
> I have to do it this way as there is a lot of server side processing

needed
> to get the arguments to pass into the dialog args, otherwise I would do it
> all client side using html buttons. Is there any way to get the parent to
> postpone posting back until the modal has shut?
>
> Thanks



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Opening modal page from modal page Don ASP .Net 0 05-27-2008 11:49 PM
Modal and non modal in same app Leila Java 0 04-26-2005 09:48 PM
How to close a parent modal window when child modal window opens? gopal srinivasan Javascript 0 11-05-2004 05:59 AM
post the form data in modal window and close the modal window. Matt HTML 1 06-01-2004 08:22 PM
post the form data in modal window and close the modal window. Matt Javascript 0 06-01-2004 07:47 PM



Advertisments