Page 2 of 3 FirstFirst 123 LastLast
Results 21 to 40 of 42
Like Tree2Likes

Thread: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

  1. #21
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    20,001
    Rep Power
    33

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    I use the word folder and directory interchangeably.

    Change to the directory with the jar file.
    If you don't understand my response, don't ignore it, ask a question.

  2. #22
    Iy13n is offline Noob
    Join Date
    Sep 2014
    Location
    Illinois
    Posts
    16
    Rep Power
    0

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    How do you do that?

  3. #23
    gimbal2 is offline Just a guy
    Join Date
    Jun 2013
    Location
    Netherlands
    Posts
    5,114
    Rep Power
    12

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    Are you at least aware that people are trying to tell you to use the command prompt?
    "Syntactic sugar causes cancer of the semicolon." -- Alan Perlis

  4. #24
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    20,001
    Rep Power
    33

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    In Windows, use the CD command to change the directory.
    What OS are you using?
    If you don't understand my response, don't ignore it, ask a question.

  5. #25
    Iy13n is offline Noob
    Join Date
    Sep 2014
    Location
    Illinois
    Posts
    16
    Rep Power
    0

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    Windows 8

  6. #26
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    20,001
    Rep Power
    33

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    Good luck then.
    If you don't understand my response, don't ignore it, ask a question.

  7. #27
    Iy13n is offline Noob
    Join Date
    Sep 2014
    Location
    Illinois
    Posts
    16
    Rep Power
    0

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    How do I use the CD command?
    (Sorry, I'm not much of a techie)

  8. #28
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    20,001
    Rep Power
    33

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    I don't know anything about Windows 8.

    Do a search on the internet for MS DOS commands. (cd is a DOS command)
    If you don't understand my response, don't ignore it, ask a question.

  9. #29
    Iy13n is offline Noob
    Join Date
    Sep 2014
    Location
    Illinois
    Posts
    16
    Rep Power
    0

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    OK so I did it and it shows:
    Does this work?
    So I'm guessing it works, but NetBeans can't run it.

  10. #30
    gimbal2 is offline Just a guy
    Join Date
    Jun 2013
    Location
    Netherlands
    Posts
    5,114
    Rep Power
    12

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    Quote Originally Posted by Iy13n View Post
    (Sorry, I'm not much of a techie)
    That's like saying that you're going to run the marathon with one leg.
    "Syntactic sugar causes cancer of the semicolon." -- Alan Perlis

  11. #31
    Tolls is offline Moderator
    Join Date
    Apr 2009
    Posts
    13,541
    Rep Power
    26

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    Quote Originally Posted by gimbal2 View Post
    That's like saying that you're going to run the marathon with one leg.
    Running On My Last Leg | 50 Marathons, 50 States, 1 Leg
    :)
    gimbal2 likes this.
    Please do not ask for code as refusal often offends.

    ** This space for rent **

  12. #32
    gimbal2 is offline Just a guy
    Join Date
    Jun 2013
    Location
    Netherlands
    Posts
    5,114
    Rep Power
    12

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    If only you could put an artificial brain in your skull to magically give you the basic computer science skills so vital for any person active in the field of ICT.
    "Syntactic sugar causes cancer of the semicolon." -- Alan Perlis

  13. #33
    Iy13n is offline Noob
    Join Date
    Sep 2014
    Location
    Illinois
    Posts
    16
    Rep Power
    0

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    Quote Originally Posted by gimbal2 View Post
    If only you could put an artificial brain in your skull to magically give you the basic computer science skills so vital for any person active in the field of ICT.
    gimbal2, if you're not going to contribute to this thread, please do not post.
    Thanks.

    So now that I know NetBeans is the problem, how can I fix it?

  14. #34
    Iy13n is offline Noob
    Join Date
    Sep 2014
    Location
    Illinois
    Posts
    16
    Rep Power
    0

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    Ok, I think I see a problem.
    When I do the instructions (Command Prompt, CD, java -jar FILENAME.jar), it only runs the first class in the project.
    I created a new package and class and only the first one ran.
    Any help on that?

  15. #35
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    20,001
    Rep Power
    33

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    it only runs the first class in the project.
    If there were no errors, then it could be ok. If the other classes aren't used, there wouldn't be an error for a missing class.
    If you don't understand my response, don't ignore it, ask a question.

  16. #36
    gimbal2 is offline Just a guy
    Join Date
    Jun 2013
    Location
    Netherlands
    Posts
    5,114
    Rep Power
    12

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    Quote Originally Posted by Iy13n View Post
    gimbal2, if you're not going to contribute to this thread, please do not post.
    Thanks.

    So now that I know NetBeans is the problem, how can I fix it?
    I wish I could contribute something, but it would be like talking to a wall. Can't help someone who doesn't learn the bare basics.
    "Syntactic sugar causes cancer of the semicolon." -- Alan Perlis

  17. #37
    Iy13n is offline Noob
    Join Date
    Sep 2014
    Location
    Illinois
    Posts
    16
    Rep Power
    0

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    So...
    how can I fix this problem, if possible?

  18. #38
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    14,423
    Blog Entries
    7
    Rep Power
    27

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    @OP: I noticed the report of this thread w.r.t. Gimbal2; NetBeans is used by zillions on users (a few more use Eclipse) so most likely its you who is doing something wrong (a trivial thing most likely); you haven't been posting much useful information and we can't look over your shoulder so all I can suggest is read the online manual for NetBeans before you try to use such a complex tool and don't blame others for not being of much help.

    kind regards,

    Jos
    Build a wall around Donald Trump; I'll pay for it.

  19. #39
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    20,001
    Rep Power
    33

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    Study how to configure the IDE. From what you have said, it looks like The jar file it produces is working properly.
    If you don't understand my response, don't ignore it, ask a question.

  20. #40
    Iy13n is offline Noob
    Join Date
    Sep 2014
    Location
    Illinois
    Posts
    16
    Rep Power
    0

    Default Re: NetBeans IDE 8.0 - Error: Could not find or load main class Java.display

    Well, I can run it using command prompt, so I guess that's ok.
    Thanks for you guys' help!

Page 2 of 3 FirstFirst 123 LastLast

Similar Threads

  1. Replies: 2
    Last Post: 10-29-2013, 08:00 PM
  2. Error: Could not find or load main class
    By iSamir in forum New To Java
    Replies: 16
    Last Post: 06-25-2013, 05:39 AM
  3. Replies: 7
    Last Post: 01-01-2012, 12:29 PM
  4. Replies: 3
    Last Post: 12-09-2011, 03:51 AM
  5. Error: Could not find or load main class Ops.java
    By Javasubbu in forum New To Java
    Replies: 4
    Last Post: 10-05-2011, 10:52 PM

Tags for this Thread

Posting Permissions

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