[SOLVED] Refocus On Edit Field
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
[SOLVED] Refocus On Edit Field
Hi Guys,
When I focus on an edit field, the keyboard presents fine, but after I move from the edit field, and refocus on it, the keyboard dose not reappear.
Any Ideas?
Many Thanks,
Matthew.
When I focus on an edit field, the keyboard presents fine, but after I move from the edit field, and refocus on it, the keyboard dose not reappear.
Any Ideas?
Many Thanks,
Matthew.
Last edited by Googie85 on Fri Apr 13, 2018 11:47 pm, edited 2 times in total.
Re: Refocus Of Edit Field
Please share your script, that would help.
-
- Livecode Opensource Backer
- Posts: 9359
- Joined: Fri Feb 19, 2010 10:17 am
- Location: Bulgaria
Re: Refocus Of Edit Field
Do you mean that this is running on Android or iOS and the onscreen keyboard appears?the keyboard presents fine
Re: Refocus Of Edit Field
Well, you could intercept the message, which would be openField, and possibly pop the keyboard that way?
Code: Select all
on openField -- triggered when clicking in the field
set the keyboardActivated to true
end openField
-
- Livecode Opensource Backer
- Posts: 9359
- Joined: Fri Feb 19, 2010 10:17 am
- Location: Bulgaria
Re: Refocus Of Edit Field
Um . . .
How about using on focusIn instead of openField ?
*Disclaimer - I don't develop for mobile, take with several grains of natural, Himalayan salt.
How about using on focusIn instead of openField ?
*Disclaimer - I don't develop for mobile, take with several grains of natural, Himalayan salt.
Re: Refocus Of Edit Field
That sounds good too
*Disclaimer - I don't develop for mobile, take with several abominable snowmen.
*Disclaimer - I don't develop for mobile, take with several abominable snowmen.
Re: [SOLVED] Refocus Of Edit Field
Thanks, you guys are awesome!!
Re: [SOLVED] Refocus On Edit Field
"set the keyboardActivated to true" will never work, because is a message sent to the current card. Can't be set.
I am having the same problem, that is:
- click on a Android (7.0 hardware) field in order to edit. OK
- write your stuff and click on a different field in order to write or edit the second field
- the keyboard disappear (noOK)
This doesn't happens on iOS
I am having the same problem, that is:
- click on a Android (7.0 hardware) field in order to edit. OK
- write your stuff and click on a different field in order to write or edit the second field
- the keyboard disappear (noOK)
This doesn't happens on iOS
Trevix
OSX 14.3.1 xCode 15 LC 10 DP7 iOS 15> Android 7>
OSX 14.3.1 xCode 15 LC 10 DP7 iOS 15> Android 7>
Re: [SOLVED] Refocus On Edit Field
Whatever it means, I discovered that if I put this in the 2 fields, the keyboard behave correctly:
Now I only need to find something a little less "intrusive"...
Code: Select all
on openField
if environment() = "mobile" then
answer "something"
end if
end openField
Trevix
OSX 14.3.1 xCode 15 LC 10 DP7 iOS 15> Android 7>
OSX 14.3.1 xCode 15 LC 10 DP7 iOS 15> Android 7>
Re: [SOLVED] Refocus On Edit Field [NOW IS SOLVED]
OK. I I put this on the 2 fields, the keyboards behave correctly.
It shouldn't need this, tought
Code: Select all
on openField
if environment() = "mobile" then
wait 10 milliseconds
focus on me
end if
end openField
Trevix
OSX 14.3.1 xCode 15 LC 10 DP7 iOS 15> Android 7>
OSX 14.3.1 xCode 15 LC 10 DP7 iOS 15> Android 7>