Code To Minick Control-A, Control-C, Control-V (Select All, Copy, Paste)

Peter Brigham MD pmbrig at
Mon Dec 6 18:13:59 EST 2010

On Dec 6, 2010, at 5:00 PM, Bob Cole wrote:

> Here is a script that I use to copy all the text in a field.
> This works on Mac OS X and Windows (XP and 7).
>   on mouseUp
>      select the text of field "myList"
>      copy
>      wait 1 second
>      select empty
>      set the vscroll of field "myList" to 0  -- reset the scroll to  
> the top of a long list
>   end mouseUp
> The select command highlights the text.
> The wait command allows time for the user to get feedback
> The select empty command removes the highlight
> The vscroll is set to the top of a long list in the field.
> With the text copied, it can be pasted into a different application.

Why not just:

set the clipboarddata{"text"] to the text of fld "myList"
answer "The text is on the clipboard." as sheet

-- Peter

Peter M. Brigham
pmbrig at

More information about the use-livecode mailing list