The opposite of "focus after" ???

Eric Chatonet eric.chatonet at sosmartsoftware.com
Wed May 9 04:46:31 EDT 2007


Hi Richmond,

Le 9 mai 07 à 10:31, Richmond Mathewson a écrit :

> So, if I want the cursor to "land" at the end of a
> string inside a text field I use:
>
> Focus after fld "XYZ"
>
> HOWEVER, I looked fairly foolish when I typed 'Focus
> before fld "XYZ"' in an attempt to get the cursor to
> "land" in front of the string!

focus on fld "XYZ" will always select after text.
Prefer to use 'select' that is more versatile:
select before text of fld "XYZ"
select after text of fld "XYZ"
select char 1 to 5 of fld "XYZ"
select word 1 to 5 of fld "XYZ"
select empty
etc.

BTW you can't use 'before' or 'after' with the focus command.

Best regards from Paris,
Eric Chatonet.
----------------------------------------------------------------
http://www.sosmartsoftware.com/
eric.chatonet at sosmartsoftware.com/
----------------------------------------------------------------





More information about the use-livecode mailing list