Resolving windows shortcut to url

Ivo ivonet at gmail.com
Fri Sep 21 16:20:00 EDT 2007


Ivo wrote:
> Richard Townsend wrote:
>> If I have a windows shortcut to a URL, is there a way to get the URL
>> in a Python app?
>>
>> I found some code that uses pythoncom to resolve shortcuts to local
>> files, but I haven't found any examples for URLs.
>>
>> The PyWin32 help mentions the PyIUniformResourceLocator Object, but I
>> couldn't find an example of how to use it.
>>
> do you mean a *.lnk file or a *.url file?

if an *.url file just open it as a properties file (ConfigParser) 
because it looks something like:


[InternetShortcut]
URL=http://ivonet.nl/
IDList=
IconFile=http://ivonet.nl/favicon.ico
IconIndex=1
[{000214A0-0000-0000-C000-000000000046}]
Prop3=19,2




More information about the Python-list mailing list