想试试Android环境有没有搭建好,结果一直提示Unsupported major.minor version 52.0

Allen1027 2016-04-12 09:12:39
刚配置Android环境想用下面helloworld的代码试一下环境,但是一直提示
Errors occurred during the build.
Errors running builder 'Android Package Builder' on project 'Hello'.
com/android/dx/command/dexer/Main : Unsupported major.minor version 52.0

小白一个,大神求解!


package com.example.hello;

import android.os.Bundle;
import android.app.Activity;
import android.view.Menu;
import android.widget.TextView;

@SuppressWarnings("unused")
public class MainActivity extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState){
super.onCreate(savedInstanceState);

TextView text = new TextView(this);
text.setText("Hello World,I love android");
setContentView(text);
}
}
...全文
4124 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
我们都有 2016-06-16
  • 打赏
  • 举报
回复
楼主怎么解决的,我现在和你一样的错误
Allen1027 2016-04-12
  • 打赏
  • 举报
回复
解决了! 谢谢大神!
Allen1027 2016-04-12
  • 打赏
  • 举报
回复
引用 1楼xingzhong128 的回复:
建议你把jdk版本升级到1.8
好的 我试试。
xingzhong128 2016-04-12
  • 打赏
  • 举报
回复
建议你把jdk版本升级到1.8

80,490

社区成员

发帖
与我相关
我的任务
社区描述
移动平台 Android
androidandroid-studioandroidx 技术论坛(原bbs)
社区管理员
  • Android
  • yechaoa
  • 失落夏天
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧