Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Adobe AIR Development

Reply
Developer
jffurlan
Posts: 1,003
Registered: ‎01-16-2011
My Device: PlayBook (sim)
My Carrier: Rogers
Accepted Solution

Specific/multiple keyboards types

Is there a way to call a specific keyboard when a user interacts with a textInput field?
Specifically numeric only?

OR

Because I think the playbook only has the qwerty keyboard and the numeric/symbol keyboard, is there a way to call the numeric one first?
- If you like my response/post, or it helped you find an answer you were looking for, please provide a Kudo - white star to the bottom right of this post. -
- Please use the search bar at the top, or check out the PlayBook FAQ's for help getting started -
- Hockey DrillBook -
Please use plain text.
Developer
JRab
Posts: 2,462
Registered: ‎11-04-2010
My Device: Bold 9700

Re: Specific/multiple keyboards types

[ Edited ]

hey jffurian,

 

im not sure exactly what you mean but, there is a TextInput class property called keyboardType that might be of interest to you. here is the link to the API details:

 

http://www.blackberry.com/developers/docs/airapi/1.0.0/qnx/ui/text/TextInput.html#keyboardType

 

if its not what you are looking for follow up and im sure we'll figure it out. good luck!

 

Edit: here is also more details about the types of keyboards you can choose from:

 

http://www.blackberry.com/developers/docs/airapi/1.0.0/qnx/ui/text/KeyboardType.html

J. Rab (Blog) (Twitter)
--
1. If you liked my post or found it useful please click on the thumbs up and provide a Like!
2. If my post solved your problem please click on the Accept as Solution button. Much appreciated!

Approved Apps: OnTrack | ssShots | Hangman
Please use plain text.
Developer
jffurlan
Posts: 1,003
Registered: ‎01-16-2011
My Device: PlayBook (sim)
My Carrier: Rogers

Re: Specific/multiple keyboards types

JRab, that's actually what I'm looking for. There is a part of my app that will need to invoke a numeric only keyboard. I just wasn't sure if it was an option. Thanks
- If you like my response/post, or it helped you find an answer you were looking for, please provide a Kudo - white star to the bottom right of this post. -
- Please use the search bar at the top, or check out the PlayBook FAQ's for help getting started -
- Hockey DrillBook -
Please use plain text.
New Developer
Nitintripathi
Posts: 12
Registered: ‎09-21-2009
My Device: Not Specified

Re: Specific/multiple keyboards types

Hi,

 

I want to call numeric only keyboard in my app but I am not able to call PIN type keyboard. Can you please let me know how to implement that.

 

I am using these in my namespace and looks like its compatible for 2009 but if I change that, it creates other issues in my code.: 

 

 

xmlns:mx="http://www.adobe.com/2006/mxml"
xmlns:s="library://ns.adobe.com/flex/spark"

 

Any suggestions ?

 

Nitin

Please use plain text.
Developer
jffurlan
Posts: 1,003
Registered: ‎01-16-2011
My Device: PlayBook (sim)
My Carrier: Rogers

Re: Specific/multiple keyboards types

Can you call other keyboards?

- If you like my response/post, or it helped you find an answer you were looking for, please provide a Kudo - white star to the bottom right of this post. -
- Please use the search bar at the top, or check out the PlayBook FAQ's for help getting started -
- Hockey DrillBook -
Please use plain text.
New Developer
Nitintripathi
Posts: 12
Registered: ‎09-21-2009
My Device: Not Specified

Re: Specific/multiple keyboards types

Yes, by default I get the regular keyboard (I am not explicitly calling it) but my app require only Numeric keyboard so I don't want the full keyboard.

 

Nitin

Please use plain text.
Developer
jffurlan
Posts: 1,003
Registered: ‎01-16-2011
My Device: PlayBook (sim)
My Carrier: Rogers

Re: Specific/multiple keyboards types

Try this:

 

 

private var textInput:TextInput;

override protected function init():void
		{
			textInput = new TextInput();
			
			super.init();
		}

                        textInput.setSize(55,28);
			textInput.setSkin(CustomTextInputSkin);
			textInput.clearIconMode = TextInputIconMode.NEVER;
			textInput.keyboardType = KeyboardType.PIN;
			textInput.returnKeyType = ReturnKeyType.NEXT;
			textInput.addEventListener(Event.CHANGE, onChange);
			
			this.addChild(textInput);

 

(This is my customSkin)

 

- If you like my response/post, or it helped you find an answer you were looking for, please provide a Kudo - white star to the bottom right of this post. -
- Please use the search bar at the top, or check out the PlayBook FAQ's for help getting started -
- Hockey DrillBook -
Please use plain text.
New Developer
Nitintripathi
Posts: 12
Registered: ‎09-21-2009
My Device: Not Specified

Re: Specific/multiple keyboards types

Hi,

 

I a mworking on .MXML not .AS.

 

I am not able to call this in there. Textinput box doesn't have keyboard type property. Do I need to import something for this ?

 

Nitin

Please use plain text.
Developer
UberschallSamsara
Posts: 1,026
Registered: ‎12-29-2010
My Device: PlayBook, Z10 LE, Dev Alpha C

Re: Specific/multiple keyboards types

If you were able to access the QNX component property (i.e. qnx.ui.text.TextInput.keyboardType) via MXML would that get the job done for you?

 

If so maybe you can follow the approach in Renaun's blog post:

 

Using MXML with QNX UI Components for the PlayBook

Please use plain text.
New Developer
Nitintripathi
Posts: 12
Registered: ‎09-21-2009
My Device: Not Specified

Re: Specific/multiple keyboards types

yes, that should work then.

 

Thanks for the pointers. I will go through the post.

 

Hope tha thelps.

 

Nitin 

Please use plain text.