NetTalk Central

Author Topic: Sending the cursor to a selected field on Login  (Read 2069 times)

Keith

  • Sr. Member
  • ****
  • Posts: 306
    • View Profile
    • Email
Sending the cursor to a selected field on Login
« on: April 03, 2015, 12:18:03 AM »
This is not a new topic really, I have asked this question before but have just come back to it and still can't get it to work.

My original question was how to send the cursor to the login Form Field that was in error (I have three fields on my Form - Business, User and Password).

Bruce said in reply:

"Loc:Invalid is set during validation to the field that you consider to be invalid, and hence the field that will regain the focus. So for example in example 3 the embed code reads;

    loc:invalid = 'Loc:Login'
    p_web.SetValue('retry','LoginForm')
    loc:Alert = 'Login Failed. Try Again.'

which will put the user back on the login field. But it could have been

    loc:invalid = 'Loc:Password'
    p_web.SetValue('retry','LoginForm')
    loc:Alert = 'Login Failed. Try Again.'

which would then put the user back on the password screen.
"

And of course this is perfectly correct, readily understood and is exactly the way that Example 3 works.

BUT - it doesn't work in my application where I code:

                 loc:invalid = 'loc:password'
                 p_web.SetValue('retry','LoginForm1')
                 loc:Alert = 'Invalid password. Try again.'           

The only difference between mine and Web3 is that my Login Form has a different name (but it was derived from the Web3 Form) - not that I think that matters.  What happens is that the Alert message appears and after clicking 'Ok' the cursor cannot be seen and it certainly is not in the Password field.

This is just an irritation but I would like to know what could be different about my Form that would generate this behaviour.

Thanks

Keith

Clarion 10.0.0 build 12799
NetTalk 9.31
StringTheory 2.65
InsightGraphing 2.27