Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PopUp / Previous <> New Window

Status
Not open for further replies.

JeroenP

Programmer
Mar 26, 2002
8
NL
Hi,

I've got a long question....
I have a page where i call this function:

function EntryAdd()
{
strReturnData = window.showModalDialog "EntryAddDlg.asp", "", "dialogWidth:450px;dialogHeight:200px;help:no;resizable:no;scroll:no;status:no;center:yes);
if( strReturnData != null )
{
self.location = strReturnData;
}
}

'When I call this prcedure a popup shows with some tekst an an input text field telling to enter a new topic.
When O.K. button is clicked. this is the procedure:

<INPUT TYPE=&quot;button&quot; VALUE=&quot;Ok&quot; onClick=&quot;OnOk()&quot; id=button1 name=button1>

function OnOk()
{
strTitel = document.forms.OkCancel.Titel.value
strURL = &quot;AchtInfoDBFuncs.asp?FUNCTION=NEW&TITEL=&quot; + strTitel + &quot;&REPOST=EntryEdit.asp?ACHTINFO=&quot;

window.returnValue = strURL
window.close()
}

-----
So far so good..
I click NEW (calls prcedure EntryAdd() ), a popup shows. I enter a topic. CLICK the OK button. Go BACK to the window where i poped from.
BUT if i do not CLICK the OK butten, but use the ENTER button on my keyboard. From the popup a new window opens. where it should close the popup and go to the Window i poped from and load that URL.

Does anybody know how to fix it?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top