[Pythonmac-SIG] Scripting iCal and using OSA?

Israel C. Evans israel at sandlotgames.com
Fri Jul 2 13:59:53 EDT 2004



Hey there folks.

I've been following the small tutorialish thing on this page 
http://stompstompstomp.com/weblog/technical/2004-02-05 and I'm not 
having much luck.

I've got python 2.3 on macosx 10.2.8 and I've used the gensuitemodule 
to create an iCal 
module-folder-with-a-bunch-of-other-modules-inside-type-doodad.

Following the directions on the aforementioned page I was able to feed 
the output of the two functions to a test log file which always came up 
changed, but still blank as , um, something that was very blank.

So I started to play and around and try hunting for things, but what I 
found didn't seem to echo what was in the iCal dictionary opened from 
within the apple script editor which seems to have a wonderful amount 
of access to just about any program that even slightly thinks about 
applescript.

->
app = iCal.iCal()
log = file('/Users/iz/proj/pythonica/osa/osatest_log.txt','w')
log.write(str('\n'.join(app.__dict__))+'\n')
log.write(str('\n'+'\n'.join(app.calendar.__dict__))+'\n')
log.write(str(app.calendar[0]))
log.flush()
log.close()
<-

This got me a text file that looks something like this:
->
target_signature
send_priority
send_flags
target
send_timeout

compclass
fr
<-
   After having read the osa docs in the python documentation, I don't 
feel a whole lot more enlightened. I'm obviously very confused about 
how to use this stuff. If any of you can find it in your heart to offer 
kind advice or point me towards any handily available founts of 
knowledge, I would be most grateful.


~Israel~


~Israel~
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: text/enriched
Size: 1686 bytes
Desc: not available
Url : http://mail.python.org/pipermail/pythonmac-sig/attachments/20040702/1ced9cc0/attachment.bin


More information about the Pythonmac-SIG mailing list