new to applescript and automator: i feel very stupid

My script is composed of 3 automator actions:

  1. “Ask for text”
  2. “Run Applescript”
  3. “New Mail message”

I want to change the text entered in step 1) with the AppleScript code at step 2) and then put it in the message of the email at step 3). However, It does not work for me, even if I have this script which does not modify anything ( I think ):

on run {input, parameters}
(* Your script goes here *)
return input
end run

I tried also:

on run {input, parameters}
(* Your script goes here *)
return first item of input
end run

because I noticed that the output was within curly braces and so it was a list. Note that If I remove the action 2) it’s working.

What i am doing wrong ?
Thanks
john

Model: MacMini
AppleScript: AppleScript 2.0.1
Browser: Firefox 3.0.1
Operating System: Mac OS X (10.5)

I have made some progress. I noticed in the logs that the output of the Run Actionscript action is being converted to Files/Folders.
The log says: "Conversion from Anything ( com.apple.applescript.object ) to Files/Folders ( com.apple.applescript.alias-object ) completed. So may be the results of the Run Actionscript are always objects ( even if returned “as text” ), and the New Mail action is trying first the conversion to Files/Folders.

The workaround now for me is using SetClipboard and GetClipboard. This seems to convert the thing to a text which is interpreted correctly by the New Mail action and goes in the message.
My start with ActionScript and Automator is not encouraging…