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 derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Extract Data From Pop up Window

Status
Not open for further replies.

IT4EVR

Programmer
Joined
Feb 15, 2006
Messages
462
Location
US
I have a web page that has a button that brings up a popup window with a calendar control on it. I want to be able to bring the date selected from the popup window to a text box on the main page? How would I go about this? Thanks...
 
The DOM's got a parent object. As in, window.parent. Your code could look like this:

Code:
<form name="formname">
<input type="text" name="txtname" />
<input type="button" onclick="window.parent.document.otherFormName.OtherTextField.value = document.formname.txtname.value" />
</form>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top