Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: How can i create an option menu? Pease help

  1. #1
    Junior Member
    Join Date
    Sep 2011
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default How can i create an option menu? Pease help

    Hello guys and girls.

    I'm trying to create a menu where you have four options:

    You can register a bird you have seen in a textfile.
    You can write the type of a bird you have seen.
    You can write the place where you have seen the bird.
    Close the program

    This is what I have done so far:

    import easyIO.*;

    class Menu {

    public static void main(String[] args) {

    int counter = 0;
    while (counter != 4) {
    counter = meny();

    switch (counter) {
    case 1:
    ReigsterBird(1);
    break;
    case 2:
    WriteBirdType(2);
    break;
    case 3:
    WritePlace(3);
    break;
    case 4:
    break;

    default:
    System.out.println("Give a number between 1 and 4");

    }
    }
    }

    But I keep getting these errors, and also i'm not sure how I can solve this. Is there something i'm missing?

    Menu.java:9: error: cannot find symbol
    counter = meny();
    ^
    symbol: method meny()
    location: class Menu
    loop.java:13: error: cannot find symbol
    ReigsterBird(1);
    ^
    symbol: method ReigsterBird(int)
    location: class Menu
    Menu.java:16: error: cannot find symbol
    WriteBirdType(2);
    ^
    symbol: method WriteBirdType(int)
    location: class Menu
    loop.java:19: error: cannot find symbol
    WritePlace(3);
    ^
    symbol: method WritePlace(int)
    location: class Menu
    4 errors

    I would appreciate if someone could help out on this so I could create a menu where you have four options you can choose from.


  2. #2
    Administrator copeg's Avatar
    Join Date
    Oct 2009
    Location
    US
    Posts
    5,318
    Thanks
    181
    Thanked 833 Times in 772 Posts
    Blog Entries
    5

    Default Re: How can i create an option menu? Pease help

    Please read the forum guidelines, and please don't double post. Duplicate of
    http://www.javaprogrammingforums.com...tatements.html
    Thread locked.

Similar Threads

  1. How can I create an option menu with while and switch statements?
    By DABBISH in forum What's Wrong With My Code?
    Replies: 4
    Last Post: September 16th, 2013, 06:36 AM
  2. How to create a Right Click Menu for a Text Field in Java?
    By deamon0 in forum AWT / Java Swing
    Replies: 1
    Last Post: July 18th, 2013, 11:20 PM
  3. Replies: 10
    Last Post: April 21st, 2013, 09:28 AM
  4. Replies: 5
    Last Post: August 11th, 2011, 12:39 PM
  5. Is it possible to use card layout for menu and menu items?
    By jai2rul in forum AWT / Java Swing
    Replies: 0
    Last Post: April 11th, 2011, 08:19 AM

Tags for this Thread