Run from command line, Wrong Name error

后端 未结 6 1881
栀梦
栀梦 2020-12-22 07:58

I want to run a Java project from the command line which I start using a batch file, but I get the wrong name error.

The directory setup:

  • srcMVC
      <
6条回答
  •  时光取名叫无心
    2020-12-22 08:52

    Assuming you have a class called Main you have to run it with this command:

    java bin\Main
    

    It will call your main method.

提交回复
热议问题