Some time, design as needed. In a window, click the button to bring up the mode window. In the mode window, after adding data (submit), close the mode window and refresh the parent window, the window in the exact mode does not support windows. therefore, the parent window cannot be obtained. That is to say, the parent window cannot be obtained after the mode window is closed. However, you can use the return value of showmodealdialog to determine whether to refresh the window. When showmodealdialog is called, the parent windowCodeIt will stop in this row. When the pop-up mode window is closed, it will be given to window. returnvalue value assignment, and then call window. close () method, and finally submit. After the data is submitted, the mode window is closed.ProgramReturn to the parent window. showmodealdialog returns the returned value. Next, you can determine whether to reload the returned value. Note: to avoid opening a new window, you must add <base target = "_ Self"/> under
code 1: parent form </P> <p> function showdatas () {</P> <p> var Re = Window. showmodaldialog ("url", "parameter", "Description"); </P> <p> If (RE = 1) {</P> <p> window. location. reload (); </P> <p >}</P> <p> Code 2: modal form </P> <p> function subform () {</P> <p> window. returnvalue = "1"; </P> <p> window. close (); </P> <p> document. getelementbyid ("myform "). submit (); </P> <p >}</P> <p>