Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 2.0 > ASP.NET 2.0 Professional
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Professional section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Display Modes
  #1 (permalink)  
Old July 11th, 2008, 02:00 AM
Authorized User
 
Join Date: Nov 2005
Location: Colombo, , Sri Lanka.
Posts: 51
Thanks: 0
Thanked 0 Times in 0 Posts
Default Javascript isnt work well on my aspx page

Hi ,

I used java script for open popup window and pass value from popup window.



This is my Popup open script

string url = "../../Default2.aspx";

string popup = "<script language='javascript'>" +
"window.open('" + url + "', 'CustomPopUp', " +

"'width=600, height=450, resizable=yes')" +
"</script>";

Page.RegisterStartupScript("Popup", popup);



This javascript work well. My secon javascript used for send value to my parent page and close my popup window. This script isnt work well. Please help me to solve it.

string aa = "aaaa";
string popup = "<script language='javascript'>" +

"window.opener.document.getElementById('TextBox1') .value = '" + aa + "'; " +
" window.close();" +

"</script>";

Page.RegisterStartupScript("Popup", popup);







Thanks


MSB
__________________
MSB
  #2 (permalink)  
Old July 11th, 2008, 09:00 AM
Friend of Wrox
 
Join Date: Nov 2007
Location: Central Florida, USA.
Posts: 207
Thanks: 2
Thanked 15 Times in 15 Posts
Default

i'm no java expert but i think you want to name your pop up windows 2 different things....


string url = "../../Default2.aspx";

string popup = "<script language='javascript'>" +
"window.open('" + url + "', 'CustomPopUp', " +

"'width=600, height=450, resizable=yes')" +
"</script>";

Page.RegisterStartupScript("Popup", popup);

string aa = "aaaa";
string popup = "<script language='javascript'>" +

"window.opener.document.getElementById('TextBox1') .value = '" + aa + "'; " +
" window.close();" +

"</script>";

Page.RegisterStartupScript("Popup", popdown);

Jason Hall
 


Thread Tools
Display Modes

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 On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
RssReader web parts now work on Default.aspx ewelling BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 12 October 6th, 2007 08:01 AM
Javascript with aspx page zaheerabbas.sk ASP.NET 1.0 and 1.1 Professional 2 April 5th, 2007 12:36 AM
Ex 401 isnt working right xlr8 BOOK: Beginning C# 2005 Databases 3 March 2nd, 2007 08:34 PM
Javascript Works Fine in Aspx page but... vivek_inos Javascript 0 June 14th, 2006 02:57 AM
can anyone see why this isnt working? ldavis Classic ASP Databases 0 January 5th, 2006 10:59 PM



All times are GMT -4. The time now is 09:03 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.