Page 1 of 1

Quick question

Posted: Mon May 11, 2009 12:08 pm
by grc
I was wondering if there was a way to ask with a button and a field.

I'd like to ask a question with a button called "Paste" which pastes the copied text into the area I want the text AND a text field to enter text into the area I want the text (if its possible a scrolling field would be great cause there's a fair bit of text).

In other words both of these put together:

Code: Select all

Ask "Please enter text here:" titled "Text Entry"
Put it into field "Text"
and

Code: Select all

Answer "Please enter text here:" with "Paste" titled "Text Entry"
If it is "Paste" then
focus field "Text"
paste
end if
Thanks :wink:

Posted: Mon May 11, 2009 10:32 pm
by WaltBrown
I put this in a field script and it worked by setting the insertion point then right clicking the mouse:

on mouseup
ask "Please enter text here" titled "Text Entry"
set the clipboardData["text"] to it
paste
end mouseup

Is this what you meant?
Walt