Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > Beginning VB 6
Password Reminder
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
Beginning VB 6 For coders who are new to Visual Basic, working in VB version 6 (not .NET).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Beginning VB 6 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 2nd, 2005, 08:54 AM
Authorized User
Join Date: Sep 2004
Location: stuttgart, , Germany.
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default Launch default browser in a new browser window

Hi all,

I want to launch default browser in a new browser window by using the code below:

Private Declare Function ShellExecute Lib _
     "shell32.dll" Alias "ShellExecuteA" _
     (ByVal hWnd As Long, ByVal lpOperation _
     As String, ByVal lpFile As String, ByVal _
     lpParameters As String, ByVal lpDirectory _
     As String, ByVal nShowCmd As Long) As Long

call ShellExecute(0&, "open", "www.google.de", vbNullString, vbNullString, SW_SHOWNORMAL)

But if there are browser windows opened, this code does not open a new browser window. The current open window is used. Does anybody know how to open a new browser window to launch default browser?

Thanks in advance,

Reply With Quote
  #2 (permalink)  
Old August 30th, 2005, 05:48 PM
Authorized User
Join Date: Aug 2005
Location: , , .
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts

In 'internet options" under teh advanced tab, there is an option labeled "reuse browser window for launching shortcuts". if checked, it appears to load in the same window. This might be an application setting that is not overridable from your external code...

Reply With Quote

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
Finding Default Browser lowell Visual Basic 2005 Basics 0 March 23rd, 2007 08:36 PM
Find default browser lowell Beginning VB 6 2 March 22nd, 2007 08:21 AM
launch executable from browser geogomez Javascript How-To 5 August 1st, 2006 10:45 AM
launch IE browser & control scroll bars ? gjelson VB How-To 0 March 15th, 2006 11:20 PM
default browser dwz VB How-To 1 November 10th, 2003 08:55 AM

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

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