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. New to the forum? Please visit the ‘Getting Started’ link below.
inside custom component

Java Development

Reply
Contributor
sujith_a
Posts: 23
Registered: ‎02-21-2012
My Carrier: Developer

Displaying states

In my application,I listed a number of country names on a screen.If I click on a country,then I need to display state names below that country..If i agan click on some other country it shows that countries states while the old states must be deleted..How can i do this??

Please use plain text.
Developer
peter_strange
Posts: 17,629
Registered: ‎07-14-2008

Re: Displaying states

I would add two ObjectChoiceFields, the Country choice Field and the State choice Field.

 

Implement a FieldChangeListener for the Country choice field, and populate the choices for the State choice field in there (see method setChoices().  .

 

Hope this is enough.

Please use plain text.