[Pythonmac-SIG] Using Python instead of AppleScript

Bill Bedford billb@mousa.demon.co.uk
Fri, 2 Aug 2002 01:47:38 +0100


At 3:14 pm -0700 01/08/02, Robin Siebler wrote:

>Can anyone give me an example of how to do this?  For instance, I have this
>AppleScript:
>
>tell application "CodeWarrior IDE 4.2.5"
>      activate
>      open file "MacOS X 10.1.3:SimpleMac.mcp"
>      dissassemble file "simple.c"
>end tell
>
>How would I do this using python instead?


Untested

import CodeWarrior

cw =3D CodeWarrior.CodeWarrior(start=3D1)
cw.activate()
cw.open(CodeWarrior.file(file1))
cw.dissemble_file(CodeWarrior.file(file2))


-- 

Bill Bedford

It was a dodgy transformer again and again.
It was a dodgy transformer that cost =A33/10