Write aaa.aspx
Result = ShowModeldialog ("1.HTM");
Form1.textbox1.value = result;
script>
In the 1.HTM
Onclick event or onunload event
write
WINDOW.VALUE = 1;