File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Choice choice = new Choice();

 
Martin vanPutten
Ranch Hand
Posts: 124
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As you can probably see... i'm having a problem with Choice. I have an arraylist already set up basically of items in a specific room and different items in another item. How can I put that into a choice.add(itemArrayList);? I thought I had my code right but apparently it couldn't be read. Does anybody know of a tutorial I can refer to for adding ArrayLists to a Choice?
 
Gregg Bolinger
GenRocket Founder
Ranch Hand
Posts: 15302
6
Chrome IntelliJ IDE Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is a Choice? What API?
 
Martin vanPutten
Ranch Hand
Posts: 124
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Choice gives you a drop down menu.
 
Craig Wood
Ranch Hand
Posts: 1535
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is a Choice?
An AWT component, antecedant to the JComboBox.
Does anybody know of a tutorial I can refer to for adding ArrayLists to a Choice?
Your best bet is to check the api. It has an add method that takes a String argument. Without generics, you might populate your Choice like this:
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic