Any way to inhibit on-screen keyboard ?

Getting into LiveCode for iOS? Ask your questions here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Any way to inhibit on-screen keyboard ?

Post by paulsr » Sat Jan 05, 2013 11:52 am

Greetings:

If I have a card with text entry fields, the on-screen keyboard seems to pop-up when the card loads.

Is there some way to inhibit this behavior, such that the keyboard only appears when the user taps inside a text entry area?

Many tkx...

--paul

dave_probertGA6e24
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 328
Joined: Mon Dec 05, 2011 5:34 pm
Contact:

Re: Any way to inhibit on-screen keyboard ?

Post by dave_probertGA6e24 » Sat Jan 05, 2013 12:17 pm

Hi,

try putting a

Code: Select all

focus on nothing
in the preopencard or opencard handler. That might work.

Cheers,
Dave
Coding in the Sun - So much Fun.
Visit http://electronic-apps.info for released App information.

paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Re: Any way to inhibit on-screen keyboard ?

Post by paulsr » Sat Jan 05, 2013 12:42 pm

Thanks Dave. I tried both places, but it didn't help.

Good advice tho for a Saturday evening ... a few beers and focus on nothing! :D

--paul

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Re: Any way to inhibit on-screen keyboard ?

Post by Mark » Sat Jan 05, 2013 2:17 pm

Code: Select all

on preOpenCard
  repeat with x = 1 to number of fields
    set the lockText of fld x to true
    set the traversalOn of fld x to false
  end repeat
  send "initiateCard" to me in 0 millisecs
end preOpenCard

on initiateCard
   repeat with x = 1 to number of fields
   set the lockText of fld x to false
    set the traversalOn of fld x to true
  end repeat
end initiateCard
Kind regards,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Re: Any way to inhibit on-screen keyboard ?

Post by paulsr » Sun Jan 06, 2013 7:49 am

Thank you Mark. That's what I needed. But tell me...

(yes, this is a bit off topic)

HOW did you know that? I'm often amazed by some of the answers I get in the forum. Does everyone treat the LC Dictionary as their favorite bedtime reading?

I had googled. I had searched the forum. And without asking for help, I don't think I would ever have found the answer.

Plowing thru the dictionary one command at a time, and trying to understand what each one does, seems to be the only way to gain a full working knowledge of LC. Or am I missing something?

--paul

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7390
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: Any way to inhibit on-screen keyboard ?

Post by jacque » Sun Jan 06, 2013 8:57 pm

paulsr wrote: HOW did you know that? I'm often amazed by some of the answers I get in the forum. Does everyone treat the LC Dictionary as their favorite bedtime reading?
I think some people probably do. :) But mostly it's just having been around long enough to have picked up all the nuances. This forum is, relatively speaking, fairly new. Before it was set up, the discussion took place exclusively on the mailing list. And that is still where most of it goes on, it's very active. Most of the professional developers are there, and some (many?) of them never read these forums. I didn't for years, I don't like a web interface very much. The list tends to discuss more advanced issues, even though they are very responsive to new users, just because that's the type of people who tend to hang out there. But even though any question is welcome and no question is too basic, new users tended to be a little intimidated sometimes. The forums solved that too.

If you'd like a double dose of LiveCode, join the mailing list. You can do that here:
http://lists.runrev.com/mailman/listinfo/use-livecode/

If you want to search the years and years of valuable info from that list, it is archived on both nabble and gmane. So in addition to searching the forums, search either of these places (they are duplicates, so you only need to choose the one you like best):

http://dir.gmane.org/gmane.comp.ide.revolution.user
http://runtime-revolution.278305.n4.nabble.com/

You will almost always find the answer to any question in the list archives.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Re: Any way to inhibit on-screen keyboard ?

Post by paulsr » Mon Jan 07, 2013 3:48 am

Thank you for taking the time to reply Jacqueline.

After a few months of coding, I was starting to feel I should be beyond the newbie stage, but I keep hitting roadblocks that only others can solve for me.

So, your message is that I need to keep coding, keep learning, keep asking questions, and in a year or three I might reach the semi-expert stage. Hmm, okay.

I confess I was only vaguely aware of the mailing list, and had assumed it was just a mirror of the forum. Now that I know otherwise, for sure, I will sign up.

The forum is a nice place though. Even the stupidest and naïvest question seems to get a polite and helpful response. That's rare. Most forums just ignore newbies, or they provide terse and unhelpful responses, that basically say, "go away, we're experts."

Okay, back to coding and learning...

--paul

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7390
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: Any way to inhibit on-screen keyboard ?

Post by jacque » Mon Jan 07, 2013 3:53 am

The mailing list is as friendly as the forums. It's a wonderful group, and many of the people you know from here are on both. You'll be right at home.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Mag
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 802
Joined: Fri Nov 16, 2012 10:51 pm

Re: Any way to inhibit on-screen keyboard ?

Post by Mag » Mon Jan 07, 2013 11:38 am

paulsr wrote:I had googled. I had searched the forum. And without asking for help, I don't think I would ever have found the answer.
I Paul, I often find myself doing your same considerations :oops: . One thing I'm learning is that LiveCode is simple and straightforward. With this in mind, you already get a part of answers for your everyday coding. So, for example, backing to the topic, you just need to know that fields which have their lockText property set to true will not let a keyboard to be used (and then shown in mobile).

Post Reply