Thread: easy fix dont know how to :(

Page 1 of 2 12 LastLast
Results 1 to 10 of 18
  1. #1 easy fix dont know how to :( 
    Registered Member
    Join Date
    Jan 2010
    Posts
    271
    Thanks given
    2
    Thanks received
    3
    Rep Power
    11
    .\src\Server.java:112: ';' expected
    Public Cooking cooking = null;
    ^
    .\src\Server.java:113: <identifier> expected
    Cooking cooking = new() Cooking;
    ^
    .\src\Server.java:113: ';' expected
    Cooking cooking = new() Cooking;
    ^
    .\src\Server.java:113: not a statement
    Cooking cooking = new() Cooking;
    ^
    4 errors
    Press any key to continue . . .
    Reply With Quote  
     

  2. #2  
    Registered Member
    Whired's Avatar
    Join Date
    Aug 2007
    Posts
    2,126
    Thanks given
    238
    Thanks received
    500
    Rep Power
    822
    I don't know if it has anything to do with the actual error, but "Public" is definitely NOT capitalized.
    Reply With Quote  
     

  3. #3 thx 
    Registered Member
    Join Date
    Jan 2010
    Posts
    271
    Thanks given
    2
    Thanks received
    3
    Rep Power
    11
    .\src\Server.java:24: <identifier> expected
    Cooking cooking = new() Cooking;
    ^
    .\src\Server.java:24: ';' expected
    Cooking cooking = new() Cooking;
    ^
    .\src\Server.java:24: <identifier> expected
    Cooking cooking = new() Cooking;
    ^
    3 errors
    Press any key to continue . . .
    Reply With Quote  
     

  4. #4  
    Project No*

    Join Date
    Aug 2007
    Age
    30
    Posts
    375
    Thanks given
    0
    Thanks received
    0
    Rep Power
    25
    could you paste the code that is 5 lines above and 5 lines below? plus please use the CODE bbcode when posting a code please.
    Reply With Quote  
     

  5. #5  
    Registered Member
    Whired's Avatar
    Join Date
    Aug 2007
    Posts
    2,126
    Thanks given
    238
    Thanks received
    500
    Rep Power
    822
    Show me everything from Server.java above line 24
    Reply With Quote  
     

  6. #6  
    Registered Member
    Join Date
    Jan 2010
    Posts
    271
    Thanks given
    2
    Thanks received
    3
    Rep Power
    11
    import java.io.BufferedReader;
    import java.io.File;
    import java.io.FileInputStream;
    import java.io.FileReader;
    import java.io.IOException;
    import java.util.ArrayList;
    import java.util.Properties;

    public class Server implements Runnable {
    public static ArrayList<String> banned = new ArrayList<String>();
    public static ArrayList<Integer> bannedUid = new ArrayList<Integer>();
    public static Server clientHandler = null; // handles all the clients
    public static java.net.ServerSocket clientListener = null;
    public static int MaxConnections = 100000;
    public static int[] ConnectionCount = new int[MaxConnections];
    public static ArrayList<String> connections = new ArrayList<String>();
    public static String[] Connections = new String[MaxConnections];
    public static DoorHandler doorHandler;
    public static GraphicsHandler GraphicsHandler = null;
    public static ItemHandler itemHandler = null;
    public static Wearing Wearing = null;
    public static Specials special = null;
    public Cooking cooking = null;
    Cooking cooking = new() Cooking;
    Reply With Quote  
     

  7. #7  
    Registered Member
    Whired's Avatar
    Join Date
    Aug 2007
    Posts
    2,126
    Thanks given
    238
    Thanks received
    500
    Rep Power
    822
    public Cooking cooking = null;
    Cooking cooking = new() Cooking;

    to

    Code:
    public Cooking cooking = new Cooking();

    Not trying to be offensive but

    http://java.sun.com/docs/books/tutorial/

    it can't hurt mate.
    Reply With Quote  
     

  8. #8  
    Project No*

    Join Date
    Aug 2007
    Age
    30
    Posts
    375
    Thanks given
    0
    Thanks received
    0
    Rep Power
    25
    Shouldnt it be

    public static Cooking cooking = null;
    cooking = new Cooking();
    Reply With Quote  
     

  9. #9  
    Registered Member
    Join Date
    Jan 2010
    Posts
    271
    Thanks given
    2
    Thanks received
    3
    Rep Power
    11
    okay
    Reply With Quote  
     

  10. #10  
    Banned

    Join Date
    Dec 2009
    Posts
    833
    Thanks given
    8
    Thanks received
    8
    Rep Power
    0
    Code:
     Cooking cooking = new() Cooking;
    Put that under main
    Reply With Quote  
     

Page 1 of 2 12 LastLast

Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •