Solved

Including Hyperlinks on forms

Posted on 2002-03-22
8
171 Views
Last Modified: 2010-05-02
How do you include hyperlinks on forms in VB6?Please help
0
Comment
Question by:coolg
8 Comments
 
LVL 43

Accepted Solution

by:
TimCottee earned 20 total points
ID: 6888905
Just put a label on the form with the appropriate colour and in the form include this code:

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
Const SW_SHOWNORMAL = 1

Private Sub Label1_Click()
    ShellExecute Me.hwnd, vbNullString, "http://www.experts-exchange.com", vbNullString, "C:\", SW_SHOWNORMAL
End Sub
0
 
LVL 7

Expert Comment

by:Joe_Griffith
ID: 6889037
For what it is worth VB.NET includes a Link control for just this purpose.
0
 
LVL 1

Expert Comment

by:COAtheGREAT
ID: 6889106
set reference to Microsoft internet controls
 
Dim ie As InternetExplorer
 
  Set ie = New InternetExplorer
  ie.Navigate "http://www.experts-exchange.com"
  ie.Visible = True
0
Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

 
LVL 1

Expert Comment

by:COAtheGREAT
ID: 6889113
Same as tim just diferent code

set reference to Microsoft internet controls

Private Sub Label1_Click()

  Dim ie As InternetExplorer
 
  Set ie = New InternetExplorer
  ie.Navigate "http://www.experts-exchange.com"
  ie.Visible = True

End Sub
0
 
LVL 1

Expert Comment

by:COAtheGREAT
ID: 6889159
Same as tim just diferent code

set reference to Microsoft internet controls

Private Sub Label1_Click()

  Dim ie As InternetExplorer
 
  Set ie = New InternetExplorer
  ie.Navigate "http://www.experts-exchange.com"
  ie.Visible = True

End Sub
0
 
LVL 6

Expert Comment

by:Nitin Sontakke
ID: 6893608
I have put my comment on the duplicate question of this.
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 7634263
Hi coolg,
It appears that you have forgotten this question. I will ask Community Support to close it unless you finalize it within 7 days. I will ask a Community Support Moderator to:

    Accept TimCottee's comment(s) as an answer.

coolg, if you think your question was not answered at all or if you need help, just post a new comment here; Community Support will help you.  DO NOT accept this comment as an answer.

EXPERTS: If you disagree with that recommendation, please post an explanatory comment.
==========
DanRollins -- EE database cleanup volunteer
0
 
LVL 1

Expert Comment

by:kodiakbear
ID: 7666163
Moving to the Paq

kb
Experts Exchange Moderator
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

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

Suggested Solutions

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
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…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

776 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