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
Regular Contributor
Posts: 77
Registered: ‎05-21-2012
My Device: 9900
Accepted Solution

Access autocompletefield's text

How to access autocompletefield's text,similar to the way a textfield's text can be accessed.

 

Statement statement1 = db.createStatement("SELECT name,phone,email FROM Directory_Items where name='"+TextField1.getText()+"'");

 Here in place of TextField1.getText( ) i would like to access the text currrently held within autocompletefield.How to go about it.

Developer
Posts: 141
Registered: ‎07-13-2011
My Device: BB Bold
My Carrier: Vodafone

Re: Access autocompletefield's text

try

 

autocompleteFld.getEditField().getText()

Regular Contributor
Posts: 77
Registered: ‎05-21-2012
My Device: 9900

Re: Access autocompletefield's text