Scripting tab

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

SparkOut
Posts: 2943
Joined: Sun Sep 23, 2007 4:58 pm

Re: Scripting tab

Post by SparkOut » Fri Feb 04, 2022 10:23 pm

Is this within your own app?

If so, look up "focus" in the docs. You can focus on the next field by script easily.

If you are trying to automate input into another app or webform, there are more complications.

andresdt
Posts: 156
Joined: Fri Aug 16, 2019 7:51 pm
Contact:

Re: Scripting tab

Post by andresdt » Fri Feb 04, 2022 10:26 pm

Create two fields and in the first place this code

Code: Select all

on enterinField
    focus on field 2
end enterinField

on returninField
    focus on field 2
end returninField

on textChanged
   focus on field 2
end textChanged
Is this what you need?
Be kind, we all have our own wars.
https://torocruzand.com/

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10305
Joined: Wed May 06, 2009 2:28 pm

Re: Scripting tab

Post by dunbarx » Fri Feb 04, 2022 11:10 pm

What andresdt said.

Yep, it is not easy to convey in words what one really means. I asked that question early on in my first response.

In LC, since everything is message driven, and messages are created by an astonishing number of events. You can trap one message or another and use it to modify the state of your stack. That modification can be to focus on another control, like a field, perhaps in layer number or by some other ordered property that is preloaded into the structure of the stack.

Getting the hang of this deserves practice on your part.

Craig

dsquance
Posts: 40
Joined: Mon Jan 18, 2010 2:47 am

Re: Scripting tab

Post by dsquance » Sat Feb 05, 2022 12:47 am

Thank you, Klaus. You were correct. That was what I wanted..
Dave

Klaus
Posts: 14177
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Scripting tab

Post by Klaus » Sat Feb 05, 2022 10:17 am

Hi Dave,

you're welcome!

@the others,

sorry folks, but I can read minds, even from far, far away!
:D :D :D


Best

Klaus

Post Reply