A great way of advertising your
site is to offer a link from the desktop
or Start Menu to your site. To do
this, you create a URL file. When
this file is double-clicked, it opens up
the default browser with the Web Site
stored in the file. The structure of the
file is as follows.
A URL file has the extension .URL,
and contains the following text:
Internet Shortcut file that points
towards Allapi.net would have the
The following code creates a
Internet Shortcut on the desktop.
Dim StrURLFile As String
Dim StrURLTarget As String
Dim FileNum As Integer
StrURLFile = "C:\Windows\Desktop\KPDHome.url"
StrURLTarget = "../"
FileNum = FreeFile
'Write the Internet Shortcut file
Open StrURLFile For Output As FileNum
Print #FileNum, "[InternetShortcut]"
Print #FileNum, "URL=" & StrURLTarget