Help | Site Map
Connecting Tech Pros Worldwide
Reply
 
LinkBack Thread Tools
  #1  
Old September 4th, 2008, 07:37 PM
Newbie
 
Join Date: Sep 2008
Posts: 1
Default passing data between windows on javascript/IE7

Hi masters, (excuse my english)

I hope you could help me with this...

I´m working with visual studio 2005 on IE7 (I think this the origen of my problem because on IE6 worked fine)...and I'm making a page which opens a popup window (window1)… on this popup, after some filters follows by a button… on the click... runs a javascript... I need the source window1 gets the values from the popup window (window2)...
here is the example

window 1:

Expand|Select|Wrap|Line Numbers
  1. <script type="text/javascript">
  2. function opener() {
  3.     window.open ('window2.aspx',"X","scrollbars=yes,status,width=450,
  4. height=450,top=0,left=0");
  5.             }
  6.     </script>
  7. ...
  8. <input id="ID" runat="server" name="ID" class="input_texto"/>
  9.  
window 2.aspx:

Expand|Select|Wrap|Line Numbers
  1. <script type="text/javascript" >
  2.         function Sel(valuex) {
  3.             window.parent.document.forms(0).item("ID").value=valuex;
  4.             window.close();
  5.         }
  6.     </script> 
  7.  
note: on IE7 doesnt work :
Expand|Select|Wrap|Line Numbers
  1. window.opener.document.getElementById("ID").value=valor;
either


do yo have any idea about it?
or something else ?

Regards...

Last edited by acoder; September 5th, 2008 at 11:44 AM. Reason: Added [code] tags
Reply
  #2  
Old September 4th, 2008, 10:44 PM
Expert
 
Join Date: Sep 2007
Posts: 846
Default

You're in the wrong forum, this should be in the JavaScript forum.
Reply
  #3  
Old September 5th, 2008, 11:48 AM
acoder's Avatar
Site Moderator
 
Join Date: Nov 2006
Location: UK
Posts: 12,727
Default

Do you get any errors? What does this line
Expand|Select|Wrap|Line Numbers
  1. <input id="ID" runat="server" name="ID" class="input_texto"/>
turn out in the browser? Is the ID still ID when you view the source in the browser?

PS. please use code tags when posting code. See How to Ask a Question. Thanks.
Reply
Reply

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over network members.
Post your question now . . .
It's fast and it's free

Popular Articles