|
-
Jan 15th, 2004, 05:18 PM
#1
Thread Starter
Addicted Member
***RESOLVED*** java combo box
first off i have to mention that i rarely use or code in java...im a VB programmer with some basic knowledge of java...i was asked to make a simple applet using threads....so i creativity came up with a horse race simulator.... The program allows a user to select a race which includes 2 to 5 horses per race and provides feedback as to which horse is the winner. The user input is validated (ie determines if the value entered for the number of races is a numeric value requested range. The race horse simulation will use separate threads for the horses. The horses race horizontally across the screen, with each horse having a different vertical coordinate.
How can I set a drop down combobox for selection of players
I was trying something like this but im not sure
Can anyone give suggestions
//combo box
Private java.awt.Select select = new java.awt select();
Last edited by annie613; Jan 16th, 2004 at 01:55 PM.
-
Jan 16th, 2004, 08:28 AM
#2
May I recommend you use Swing instead of AWT? Derive your applet class from javax.swing.JApplet instead of java.applet.Applet.
Then you can use the (easier to use) Swing components.
The component you're looking for is JComboBox, with setEditable(false) called after construction.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Jan 16th, 2004, 10:00 AM
#3
Thread Starter
Addicted Member
thanks that makes things easier
cheers annie
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|