JComboBox and IF Statement
I am new to Java, and have been trying to make a program for my college course. I have come to a bit of a dead end.
I am trying to make a JComboBox that is linked to a If statement.
I want to make a JComboBox with three options (Natural, Yorkstone and Clay) and then create an If statement for it like (pseudocode):
if (JComboBox = Natural)
type = 1;
else if (JComboBox = Yorkstone);
type = 2;
type = 3;
Any ideas would be greatly appreceated.
Thanks in advance.
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL