Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 1.0 and 1.1 > ASP.NET 1.0 and 1.1 Basics
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
ASP.NET 1.0 and 1.1 Basics ASP.NET discussion for users new to coding in ASP.NET 1.0 or 1.1. NOT for the older "classic" ASP 3 or the newer ASP.NET 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Basics 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 Search this Thread Display Modes
  #1 (permalink)  
Old August 30th, 2007, 01:24 AM
Registered User
 
Join Date: Aug 2007
Location: Kollam, Kerala, India.
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default opening a webpage in a new window

I am creating a simple application in asp.net using visual basic as my language. I have multiple web forms in my application. Whenever I click a link in one of my web forms I have redirected the control to another web form. I want this new web form (web page) to be opened in a new internet explorer window without right clicking the link and selecting the 'open in new window' item. Can anyone please help

Hahaha
  #2 (permalink)  
Old August 30th, 2007, 08:01 AM
Wrox Author
Points: 13,255, Level: 49
Points: 13,255, Level: 49 Points: 13,255, Level: 49 Points: 13,255, Level: 49
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2005
Location: Ohio, USA
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

The easiest way would be to just specifiy the target attribute of the link as '_blank'

<a href="foo.aspx" target="_blank">text</a>

You could also add a JavaScript to the onclick event to call window.open();

hth.

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
================================================== =========
Technical Editor for:
Professional Search Engine Optimization with ASP.NET

Professional IIS 7 and ASP.NET Integrated Programming

================================================== =========
  #3 (permalink)  
Old August 30th, 2007, 11:55 PM
Registered User
 
Join Date: Aug 2007
Location: Kollam, Kerala, India.
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Could u please post the code to add a javascript to the onclick.

Hai
  #4 (permalink)  
Old August 31st, 2007, 06:56 AM
Friend of Wrox
Points: 1,935, Level: 17
Points: 1,935, Level: 17 Points: 1,935, Level: 17 Points: 1,935, Level: 17
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2004
Location: United Kingdom
Posts: 550
Thanks: 0
Thanked 1 Time in 1 Post
Default

Are you talking about client side code? It could be something simple as below:

<a href="#" onclick="yourjsfunctionname()"></a>

Regards
Mike

To the world you might be one person,
but for someone you might be the whole world.
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
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
Opening a New Window GailCG ASP.NET 2.0 Basics 14 April 1st, 2008 11:32 AM
Opening New Window p_nut33 Classic ASP Basics 1 August 6th, 2004 08:11 PM
Close Parent window on opening child window pkdev Javascript How-To 8 April 11th, 2004 12:06 PM
Pop-up window, on top of webpage Burton HTML Code Clinic 5 September 3rd, 2003 04:29 AM
Opening New Window james_sellwood ASP.NET 1.0 and 1.1 Basics 5 June 12th, 2003 11:43 AM



All times are GMT -4. The time now is 04:40 PM.


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