码迷,mamicode.com
首页 > 系统相关 > 详细

Eclipse:The selection cannot be launched,and there are no recent launches

时间:2017-03-12 14:53:11      阅读:324      评论:0      收藏:0      [点我收藏+]

标签:不能   cat   ges   窗口   意思   网上   run   lips   问题   

  刚刚装上eclipse,于是就想写个Java程序来试试。结果写好之后不管是点击 run  还是  debug 结果都会弹出一个窗口,内容为: The selection cannot be launched,and there are no recent launches !意思是该选项不能执行,最近没有执行的记录。

这是我写的Java程序

  技术分享

后来在网上找了很久都没找到想要的答案。都是说要:选择Run,点击执行 run as application。然后我点击了run,确找不到 run as application 。后来才发现是因为语法问题导致的出错。

纠正后的Java程序:

  技术分享

总结了一下,出现The selection cannot be launched,and there are no recent launches !问题时:

  1、先确定语法有没有问题,程序没有出现红色的波浪线并不代表就是没有问题。

  技术分享

  2、语法没有问题前提下,选中要执行的文件,点击右键,选择Run,点击执行 run as application。

纠正后执行出来的程序:

  技术分享

 

Eclipse:The selection cannot be launched,and there are no recent launches

标签:不能   cat   ges   窗口   意思   网上   run   lips   问题   

原文地址:http://www.cnblogs.com/ranter/p/6537621.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!