Function to get URL from Windows internet shortcut (.url)
Function to get URL from Windows internet shortcut (.url)
Rate Function to get URL from Windows internet shortcut (.url)
(1(1 Vote))
Dim Useless, URL As String
Open Filename For Input As #1
Input #1, Useless
Input #1, URL
Close #1
If Left$(URL, 4) = "URL=" Then
URL = Right$(URL, Len(URL) - 4)
ElseIf Left$(URL, 4) = "BASE" Then
URL = Right$(URL, Len(URL) - 8)
End If
GetURLFromFile = URL
End Function
'Example:
'MyURL = GetURLFromFile("c:\windows\favorites\shortcut.url")
'would return the http://www.whatever.com address
Function to get URL from Windows internet shortcut (.url) Comments
No comments yet — be the first to post one!
Post a Comment