I don't believe IShellLink uses Dispatch/automation objects, so you will have to import the tlb information
Microsoft supplies the idl and h file in shobjidl.idl and shobjidl.h You can use midl to create a tlb from it. Then you should be able to load the tlb into comtypes. -----Original Message----- From: Markus Gritsch [mailto:[EMAIL PROTECTED] Sent: Monday, November 03, 2008 9:51 AM To: comtypes-users@lists.sourceforge.net Subject: Re: [comtypes-users] Creating Shell Links using comtypes On Mon, Nov 3, 2008 at 3:16 PM, MR Michael Robellard (5314) <[EMAIL PROTECTED]> wrote: > > To be more helpful I think we would need to know where your code is > dying, and what error messages you are getting. I tried the following: import sys import comtypes from comtypes.client import CreateObject CLSID_ShellLink = '{00021401-0000-0000-C000-000000000046}' IID_IShellLink = '{000214EE-0000-0000-C000-000000000046}' shortcut = CreateObject(CLSID_ShellLink, comtypes.CLSCTX_INPROC_SERVER) shortcut.SetPath(sys.executable) and got an AttributeError: 'POINTER(IUnknown)' object has no attribute 'SetPath' ------------------------------------------------------------------------ - This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ comtypes-users mailing list comtypes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/comtypes-users ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ comtypes-users mailing list comtypes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/comtypes-users