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

Java Development

Reply
New Developer
nnvnaveen
Posts: 36
Registered: ‎10-29-2009
My Device: Not Specified

how to call onFocus()

Hi All,

 

I have a situation to call the on focus method explicitly. how to call onFocus() method explicitly.

 

 

I Have return isFocussable(){

return true;

}

 

But in my application onFocus() method is not calling. plse do help me!!!

Please use plain text.
Developer
peter_strange
Posts: 19,595
Registered: ‎07-14-2008
My Device: Not Specified

Re: how to call onFocus()

If you want a Field to have the focus, call setFocus on that Field. 

 

onFocus is a 'listener' that is told when the Field received focus. 

Please use plain text.
New Developer
nnvnaveen
Posts: 36
Registered: ‎10-29-2009
My Device: Not Specified

Re: how to call onFocus()

I have used setFocus() method also . But it is not getting.

Please use plain text.
Developer
peter_strange
Posts: 19,595
Registered: ‎07-14-2008
My Device: Not Specified

Re: how to call onFocus()

I am not aware of any problems with this method, so I suspect it is something in the way that you are using it.  Perhaps you should just create a simple example to make sure you are using this correctly.

Please use plain text.