?
Solved

How to make an button launch a URL

Posted on 1999-06-25
7
Medium Priority
?
153 Views
Last Modified: 2010-05-02
I only have 77 points left but they're yours if you can tell me how to program a command button to launch a URL.
0
Comment
Question by:rfb1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
7 Comments
 
LVL 7

Expert Comment

by:KangaRoo
ID: 1519697
In VBA there is the FollowHyperLink method
0
 
LVL 4

Accepted Solution

by:
Radler earned 140 total points
ID: 1519698
use:
ShellExecute(GetDesktopWindow, "open", path_to_url, NULL, NULL, SW_SHOWNORMAL).

0
 

Author Comment

by:rfb1
ID: 1519699
Radler:
this errors..what is wrong?

Private Sub Command1_Click()
ShellExecute(GetDesktopWindow, "open", "C:\awork\control.htm", NULL, NULL, SW_SHOWNORMAL)
End Sub
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:rfb1
ID: 1519700
Radler:
this errors..what is wrong?

Private Sub Command1_Click()
ShellExecute(GetDesktopWindow, "open", "C:\awork\control.htm", NULL, NULL, SW_SHOWNORMAL)
End Sub
0
 
LVL 12

Expert Comment

by:mark2150
ID: 1519701
You can also drop the WebBrowser control on your form and code:

WebBrowser1.Navigate URL

M

0
 

Author Comment

by:rfb1
ID: 1519702
MARK2150...

I am running VB6 but don't see a web browser control.

0
 
LVL 12

Expert Comment

by:mark2150
ID: 1519703
You have to load it in. <Ctrl T>, look for Microsoft Internet Controls. It'll add two icons to the toolbar. Grab the little Globe icon and drop it on the system. It's a dependency of IE4. If you don't have IE4 installed you won't have the icon. My web page has a browser based on this control:

www.cyberchute.com/rvbus/madmark


M

0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses

718 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question