C-Command Software Forum

e-mail-file.scpt with notes field as message text

hi All,

I’m currently using the script mentioned in Title. It all works as promised, great! Could someone maybe tell me how to have the script use the “Notes” field from the “Info window” as message text?

Thanks for any reply,

Gert

I’ve modified the script to include the notes.

Applescript: set content to _body
thanks for your prompt reply

I’m not much of an Applescripter but just tried the script and guess we’re almost there only…

    set _body to _body & _record's note text & return

does work but then the note doesn’t get picked up as body because

set content to _body

isn’t working on my machine. Don’t know what’s going on.
Thanks,
Gert

When you say it isn’t working, what do you mean, exactly? Is an error reported? Which version of Mac OS X do you have?

just don’t get the expected result. An e-mail with the info as text in the body of the e-mail. No errors.
I use 10.5.6 and I’ll paste the event log of Applescript below


tell application "EagleFiler"
	get selected records of browser window 1
		{library record id 115 of library document "my_know_how.eflibrary"}
	get file of library record id 115 of library document "my_know_how.eflibrary"
		file "Macintosh HD:Users:gert_MBP:Documents:my_know_how:Files:Verhaal7.tex"
	get note text of library record id 115 of library document "my_know_how.eflibrary"
		"testing a note field for mail"
end tell
tell application "Mail"
	make new outgoing message with properties {visible:true}
		outgoing message id 421990816
	get message signature of outgoing message id 421990816
		missing value
	make new attachment at end of outgoing message id 421990816 with properties {file name:"/Users/gert_MBP/Documents/my_know_how/Files/Verhaal7.tex"}
end tell

I think there was an error with your signature. Please try the updated script.

After restarting Mail it works, very good!

Thanks for this script and for the great application!

Gert