Click here to Skip to main content
15,891,529 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
JavaScript
var result;
           var url = form + frmArgs;
           $.showModalDialog({
               url: url,
               dialogArguments: window,
               height: 470,
               width: 400,
               scrollable: false,
               onClose: function () {
                   var returnedValue = this.returnValue;
                   result=returnedValue;
               }
           });


what does mean by this line of code from above code

var returnedValue = this.returnValue;
Posted
Updated 8-May-13 2:42am
v4
Comments
Brian A Stephens 8-May-13 9:15am    
What does this have to do with asp.net or an IFrame?
[no name] 8-May-13 9:17am    
i am using jquery IFrame
Please check my answer.
[no name] 9-May-13 2:26am    
Hi Dash,
thankyou so much for the nice post it is realy helpfull
but i have some question
is there any way to stop the further execution and wait for the popup to close.
in javascript or jquery
please help........


Most welcome...

So, you want to close that popup automatically after some time interval or what ?
Can you elaborate...

1 solution

Here this.returnValue is the value returned from that target file showing on Modal.

On that file if you specify what to return, then this will contain the return value like below.
XML
<script type="text/javascript">
    function closeMe() {
        window.returnValue = 'The Return Value + ' + window.dialogArguments;
        window.close();
    }
</script>

Here it is returning the message as "The Return Value" appended with the arguments you sent.
You have sent window as the arguments.

Refer - IE window.showModalDialog() - Cross Browser solution[^].
Go through the article and you will understand completely.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900