473,508 Members | 2,303 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

pass field to child window

Hi, I am writing a javascript function. The idea is this very similar
to the "color picker":

1. You have a html page where you have many text fields. Suppose each
of them is a child's name. Besides each of the text fields you have a
button.
2. If you click the button, my javascript function will open a new
browser window. In that window, I will show other names that are very
similar to this one.
3. If user selects a new name in this new window, my javascript
function will close the new window and put the new name in the text
field in the old window. Thus, the new window has to have a reference
to the text field.

I now have no problem to open the new window and display list of names.
My problem is how to pass the reference of the text field to the new
window. Since I have many many text fields and all of them use the same
function, I can not hard-code the text-field in the javascript
function.

Please help.

qq

Jul 13 '06 #1
3 2449

<qu******@yahoo.comwrote in message news:11**********************@m79g2000cwm.googlegr oups.com...
I now have no problem to open the new window and display list of names.
My problem is how to pass the reference of the text field to the new
window. Since I have many many text fields and all of them use the same
function, I can not hard-code the text-field in the javascript
function.
What function ? If you post your existing code, you're more likely to get helpful suggestions as to how to improve it...

Tim

>
Please help.

qq

Jul 13 '06 #2

var win = window.open("etc");
win.text = "my new color etc etc"
then inside the new window:
window.onload = function () {
alert (window.text);
}

Jul 13 '06 #3
You sure this is going to work? I got "is NULL" or "undefined"
go*****@gmail.com wrote:
var win = window.open("etc");
win.text = "my new color etc etc"
then inside the new window:
window.onload = function () {
alert (window.text);
}
Jul 13 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2823
by: Filiz Duman | last post by:
Hi, I am opening a pop up window (child) from a parent window. The Child window does show a table with multiple columns and rows, each showing a value, e.g. 9 or 10 or etc. I have the values as...
0
1591
by: jmrieman | last post by:
first off, I am an IT pro trying to dust off the cobwebs of programming in a Master degree program so please be nice:) I am trying to pass a system.array object by reference to a procedure (or...
3
1610
by: Chris | last post by:
I have a modal (yes it must be modal) web page. I do this by having an empty frame that points to my main page (so that I can repost without new popups) I have to pass data to the child page from...
1
11537
by: Earl Teigrob | last post by:
I did a ton of searching to try and find a simple solution to this issue and finally wrote my own, which I am sharing with everyone. In my searching, I did find a very complete and robust solution at...
10
2487
by: Sean Dockery | last post by:
I have the following HTML file that I've been using for testing... <html> <head> <script type="text/javascript"> <!-- function handleWindowLoad() { var items = ; for (var i = 0; i < 11; i++)...
6
4716
by: kath | last post by:
hi everyone......... I have a task, I have fragmented the task into subtask. I have planned to create a class to each subclass and one parent class to handle the sub tasks. Each subclass are...
0
2027
by: hcuellar | last post by:
Hi. Please I need your help for this: After a database query, a table is created with a cell for each information retrieved, and for each record, two buttons, and second one have besides it...
1
9326
by: colleen1980 | last post by:
Hi: Can any one please tell me that how to i pass the two textbox values in the new page. If i use the form action in the popup window page then the new page is open in the same popup window as i...
2
2191
by: rishhi04 | last post by:
how to pass jsp child window value to parent jsp window .particular field or focus field
0
7225
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7324
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7382
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
5627
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5052
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3193
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3181
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1556
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
766
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.