Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > General Computer Discussion > Software > problem with javascript

Reply
Thread Tools

problem with javascript

 
 
dootam dootam is offline
Junior Member
Join Date: Jul 2007
Posts: 2
 
      07-10-2007
I am using ASP.NET 2.0, C# and javascript to open a new browser window and encounter the following problem:

On Page1.aspx I have a button with the following click event:

Response.Write("<script>window.open('Page2.aspx',' _new');</script>");

This works as expected.

On Page2.aspx I have again a button with the following click event:

Response.Write("<script>window.open('Page3.aspx',' _new');</script>");

This is my problem; Page3.aspx does not open in a new window, instead it opens in the same window. I want a new window and when a user finishes with Page3, the new window closes and the user is back in Page2.aspx.

Thank you in advance for your help.
 
Reply With Quote
 
 
 
 
dootam dootam is offline
Junior Member
Join Date: Jul 2007
Posts: 2
 
      07-10-2007
Problem solved by replacing '_new' with '_blank'.
Thanks for the help from
Phil Weber
Microsoft MVP
http://www.philweber.com
 
Reply With Quote
 
 
 
Reply

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Generated JavaScript vs. Manually Created JavaScript: Which one comes first? Nathan Sokalski ASP .Net 4 11-08-2007 07:24 AM
JavaScript or not JavaScript Mark Rae ASP .Net 36 09-09-2006 01:12 PM
href="javascript:func()" vs href="#" onclick="javascript:func()" CRON HTML 24 06-20-2006 08:05 PM
Javascript -> Applet: variable reset after method call from javascript?! mcdeveloper Java 1 06-13-2006 08:34 AM
tricky javascript problem requires javascript guru ! Andy Javascript 2 03-04-2004 08:19 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57