关于安卓启动模拟器时出现~~~~have you declared this activity in your AndroidMainfest.xml?问题

来源:互联网 发布:华3交换机端口激活命令 编辑:程序博客网 时间:2024/05/21 08:54

运行模拟器时t出现这个报错怎么解决

Android.content.ActivityNotFoundException: Unable to find explicit activity class {com.example.iceyousdk/com.example.iceyousdk.LoginActivity}; have you declared this activity in your AndroidManifest.xml?ontent.ActivityNotFoundException: Unable to find explicit activity class {com.example.iceyousdk/com.example.iceyousdk.LoginActivity}; have you declared this activity in your AndroidManifest.xml?

那么这种问题的解决方法有哪些呢?

本人多次遇到,总结如下:

1.没有注册

解决方法:安卓四大组件都要在androidMainfest中注册。记住一定要在application的标签下面。

2.包名或Java文件在注册时跟源文件不一样

解决方法:仔细点检查,包名做好是有cn.(com.)这样的形式类似:cn.itcast.mobliesafe.chapter01.utils

如果一上两点都没错的话,还是有这个问题,那就重启下新建个模拟器试试






1 1