Javascript Reference
Categories: window

javascript window returnValue

@July 25, 2008, 2:12 p.m.
returnValue Firefox/Netscape/NN n/a IE 4(Win)/5(Mac) Chrome/Safari/DOM n/a  
  Read/Write  

A value to be returned to the main window when an IE dialog window (generated by  showModalDialog( ) method only) closes. The value assigned to this property in a script running in the dialog window becomes the value returned by the showModalDialog( ) method in the main window. For example, the document in the modal dialog window may have a statement that sets the returnValue property with information from the dialog:

window.returnValue = window.document.forms[0].userName.value;

The dialog is created in the main document with a statement like the following:

var userName = showModalDialog("userNamePrompt.html");

Whatever value is assigned to returnValue in the dialog is then assigned to the userName variable when the dialog box closes and script execution continues.

 
Value

Any scriptable data type.

 
Default

None.

Im grateful for the forum topic.Really looking forward to read more. Fantastic. Panke
WilliamWhox - 2 years
I have the same problem.
javac - 4 years
<a href=></a>
<a href=></a>
<a href=></a>
<a href=></a>
<a href=></a>
<a href=></a>
<a href=></a>
<a href=></a>
PestrogsPat - 2013-06-29

Powered by Linode.