(使用-source 7或更高版本来启用switch中的字符串)错误; Netbeans 7.1.2 [英] (use -source 7 or higher to enable strings in switch) error;Netbeans 7.1.2

查看:92
本文介绍了(使用-source 7或更高版本来启用switch中的字符串)错误; Netbeans 7.1.2的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用JDK 7和Netbeans IDE 7.1.2.通过在switch中使用字符串

I am using JDK 7 and Netbeans IDE 7.1.2. Going through Using string in switch

试图在我的IDE中编译该示例示例,但出现此错误.

Was trying to compile that sample example in my IDE but I am getting this error.

开关(month.toLowerCase()){ (使用-source 7或更高版本来启用switch中的字符串) 1个错误

switch (month.toLowerCase()) { (use -source 7 or higher to enable strings in switch) 1 error

需要您的帮助.
谢谢

Need your help.
Thanks

推荐答案

您需要设置项目的源代码

You need to set the source for your project,

右键单击>属性>源>在此处设置

right click > properties > source > set here

这篇关于(使用-source 7或更高版本来启用switch中的字符串)错误; Netbeans 7.1.2的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆