Re: Freedom Writers script
Re: Freedom Writers script
- Subject: Re: Freedom Writers script
- From: Matthew Stuckwisch <email@hidden>
- Date: Sat, 11 May 2002 11:06:56 -0500
I'm a group leader for Amnesty International, and I use AppleWorks to
help the members of my group write their letters. I'd like to use AS to
improve the process. Here's the beginning:
1. Unfortunately, iCab launches before Internet Connect has connected.
How do I make iCab wait for, say, 60 seconds while the modem connects?
Is there a way to have iCab start right as soon as the modem has
connected?
tell application "Internet Connect"
connect
end tell
delay 60
tell application "iCab"
OpenURL "
http://www.amnestyusa.org/freedomwriters/fw1.html"
end tell
OR
tell application "Internet Connect"
connect
end tell
repeat until a does not begin with "curl: (6) Couldn't resolve host"
set a to (do shell script "curl --connect-timeout 1 www.apple.com")
end repeat
tell application "iCab"
OpenURL "
http://www.amnestyusa.org/freedomwriters/fw1.html"
end tell
The top one will just wait, the second one will loop until curl doesn't
error on Apple's site.
2. Once I'm on that web page (or any similar page) how do I copy all of
the text on that page? I figure once I can copy it I can paste it into
AppleWorks, but that's the next step and I'm not ready for that just yet.
I haven't done much scripting with either AppleWorks or iCab, sorry
Matthew Stuckwisch
[AIM/MSN]{GuifaSwimmer} | [Yahoo!]{SapphireTree} | [ICQ]{137477701}
[IRC]{guifa / G}(esperNET / irc.massinova.com)
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.