开发者

How to tell eclipse java what to run

开发者 https://www.devze.com 2023-02-21 03:15 出处:网络
I just downloaded Eclipse Java and am lookin开发者_StackOverflow中文版g to finish my hello world tutorial but I\'m not sure what packages to include in my app and Eclipse doesn\'t like that I don\'t h

I just downloaded Eclipse Java and am lookin开发者_StackOverflow中文版g to finish my hello world tutorial but I'm not sure what packages to include in my app and Eclipse doesn't like that I don't have any packages specified. Any advice?

tutorial link:

http://download.oracle.com/javase/tutorial/getStarted/application/index.html


Look into this Hello Eclipse example. It tell you how to code in Java using Eclipse (including creation of package and running it). Also, how to run the code from out side the Eclipse.

Hope this helps.


Right-click on the src folder of your project and choose to create a new package. Give the package any name you want, for example webnet.helloworldapp. Then move your existing sources under that package with the Refactor --> Move command, or just manually add the following line to the files:

package webnet.helloworldapp;

0

精彩评论

暂无评论...
验证码 换一张
取 消