-- Usage: Select text in the body of a message (maybe in the header as well), then run
-- this script. It will create a new message with the quoted text of the current message,
-- and the selected text in the recipient field (To:).
-- If the control key is pressed, the body of the new message will be left empty.
-- Needs Scripting Addition "Jon's Commands".
-- Markus Frischknecht (mailto:mfrischknecht@access.ch) 1998.
-- This script is public domain. Use and change at will, but if you release a
-- modified version please include the information above.
-- Eudora should be running (e.g. use with Script plug-in)
-- if control key down: empty body in reply message
set emptyBody to ("Control" is in (keys pressed)) -- OSA Menu uses "option" for itself
-- set up double tell mechanism
tell application "Finder"
try
-- MacOS 8.0 and 8.1, but also works for Sys 7.5 and 7.6
set EU to (process 1 whose creator type is "CSOm") as «class psn »
on error
-- Eudora is not running, so abort
beep
end try
end tell
tell application "Eudora Pro 3.1.3" to tell EU
set sendTo to selected text
set newMsg to reply message ""
set field "to" of newMsg to sendTo
if emptyBody then
-- clear body text of new message
set field "" of newMsg to ""
end if
end tell