Detect when a field changes

Peter Haworth pete at lcsql.com
Sat Nov 16 19:04:07 EST 2013


>From the dictionary:

"Is dispatched by the field whenever a user (or simulated user) action
causes the content of the field to change."

What is a "simulated user" I wonder....

I guess you could also send a textChanged message to the field, or pull the
textChanged logic into a separate handler and call it from textChanged and
wherever else you put text into the field.

Pete
lcSQL Software <http://www.lcsql.com>


On Sat, Nov 16, 2013 at 2:47 PM, AndyP <smudge.andy at googlemail.com> wrote:

> Hi Bill,
>
> Thought this was odd so made a little test stack... and yes you are right
> and focus has no effect.
>
> Now it seems that the textChanged meassage is only sent when Typing in a
> field has happened and not when the contents of the field actualy change!
>
> There is a way around the problem. I'm assuming you using a put to get your
> contents into the field.
>
> Try using the Type command instead. This simulates physical typing in the
> field.
>
> You can do something like this;
>
>
> select after fld "MyField"
> set the typingRate to 0 // no delay
> Type "MyStuffHere" // instaed of put
>
>
>
>
>
>
>
>
> -----
> Andy Piddock
>
>
> My software never has bugs. It just develops random features.
>
> Copy the new cloud space, get your free 15GB space now:
> Get Copy
>
>
> Your LiveCode Work Desks - New Blog
> http://livecodemydesk.blogspot.de/
>
> PointandSee is a FREE simple but full featured under cursor colour picker
> / finder.
> http://www.pointandsee.co.uk  - made with LiveCode
> --
> View this message in context:
> http://runtime-revolution.278305.n4.nabble.com/Detect-when-a-field-changes-tp4672425p4672429.html
> Sent from the Revolution - User mailing list archive at Nabble.com.
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>



More information about the use-livecode mailing list