各位高手,我在用Java写界面时,用到JFrame时就出错,Java环境变量也配置正确,错误提示如下:
Access restriction: The type JFrame is not accessible due to restriction on required library C:\Program Files\Java\jre7\lib\rt.jar
------解决方案--------------------
Project -> Properties -> libraries,
先remove掉JRE System Library,然后再Add Library重新加入C:\Program Files\Java\jre7\lib下面的 .jar 包。