Can't find simple Applescript for use in Apple Mail - been looking for hours

From within FileMaker I generate an email based on the current record. Much searching produced a Stack Overflow solution to step 1 - Make active my new Email message with the cursor inserted to the To: field...

One email is open at a time by a FileMaker Pro script (not AppleScript).

tell application "System Events"
set frontmost of process "mail" to true
tell application "Mail"
   set x to get id of window 1
   activate
   if id of window 1 is x then
       set index of window 2 to 1
   end if
end tell
tell application "System Events"
   tell process "Mail"
       perform action "AXRaise" of window 1
tell application "System Events"

end tell
end tell
end tell

Delay 1.0

If the main email window is open the new email is not "active". If the main email window is hidden the new email is active.

I have the email address in the clipboard and a manual paste will deliver it. All the suggested AppleScript methods of pasting into the email To: field I have found have not worked - just do nothing. What am I missing?

Also, would like to automatically insert "The Latest Invoice from Criterion Labs Inc. into the Subject: field.