Why... is the selected text deselected?

Scott Rossi scott at tactilemedia.com
Wed Feb 19 22:10:01 EST 2003


Recently, "Alex Rice"  wrote:

>> Works okay here. Check the properties of the field, and make sure that
>> the field's listBehavior property is true. Also make sure you aren't
>> accidentally running a copy of the field on the second card -- make
>> sure the first card's field is really the one that is placed on the
>> second card.
> 
> That's just it- the field is only intended to be on the first card.
> Second card has other stuff on it. I guess I wasn't being clear about
> that.

Not sure if this is what you're after, but if you're just trying to
re-select text in a field, you could place this in the card script:

on preOpenCard
   select line 1 of fld myField
end preOpenCard

Or, to place the cursor before the text:

on preOpenCard
   select before line 1 of fld myField
end preOpenCard

You may need to use a variable or custom property to store the specifics of
your text selection, and you might want to use a variable/property to
trigger the auto-selection only after the user has returned from the second
card.

Regards,

Scott Rossi
Creative Director
Tactile Media, Multimedia & Design
-----
E: scott at tactilemedia.com
W: http://www.tactilemedia.com




More information about the use-livecode mailing list