In article <[EMAIL PROTECTED]>, Bill Janssen <[EMAIL PROTECTED]> 
wrote:
> I'm trying to add a login item in an installer, and I thought using
> appscript would be the simplest way.
> 
> >>> from appscript import *
> >>> a = app("System Events")
> >>> a.login_items()
> 
> Sure enough, a display of items.  But how do I create a new one and add
> it?

a.login_items.end.make(new=k.login_item, 
    with_properties={k.path:"/Applications/TextEdit.app", k.hidden:True})

(Adapted and translated from the AppleScript here: 
<http://macstuff.beachdogs.org/blog/?p=30>)

-- 
 Ned Deily,
 [EMAIL PROTECTED]

_______________________________________________
Pythonmac-SIG maillist  -  Pythonmac-SIG@python.org
http://mail.python.org/mailman/listinfo/pythonmac-sig

Reply via email to