the application has stopped unexpected。please try again的解决办法
2012-03-10 11:00
676 查看
1. 运行程序后弹出: The application *** has stopped
unexpectedly. Please try again. 然后会要祈求强制退出。
这是一个经典错误, Socket不能对外连接,具体错误不会被
报出,调试的时候,但能看到Exception,, 只要存在网络互联,
就挺身而出,让你的程序不得运行。
原因是: 需要访问到网络,所以,在AndroidManifest.xml
中,需要进行如下配置:
在下面第三个页面permission中,选择“Add...”选择“uses
permission”,在右面name中选择
“android.permission.INTERNET” ;然后在
AndroidManifest.xml中会出现下面语句:
<uses-permission
android:name="android.permission.INTERNET" />
再次运行程序,就OK了。
2. 出现错误“The *** has not responding”:
原因有如下几种:服务器没有打开、
客户端要连接的IP不对、
Server和Client的端口不一致
、
客户端与服务器的接收和发送
没有一一对应,
导致等待超时,出现异常。
但是我的问题还为解决?
3。在学习Android的时候,偶尔会遇到异常。像要是遇到异常:“The application has stopped unexpectedly”的时候,首先去查看自己的代码是否有逻辑上的错误或者是漏洞,例如是不是使用了一个null对象。对象使用之前是否已经实例化。另外针对Android要特别注意,整个的程序中要关心的有三个部分:
业务逻辑--即逻辑上是否合理,代码部分是否正确。这个主要可以通过调试运行查看Log记录。
资源应用--Android的资源都放在了res文件下面,如Activity的布局一般都放在res/layout下面,并且一般是一个xml文件对应一个Activity。
AndroidManifest.xml--之前我在学习别人一个例子的时候就忽略了这个非常重要的东西,才导致了The application has stopped unexpectedly的发生。
unexpectedly. Please try again. 然后会要祈求强制退出。
这是一个经典错误, Socket不能对外连接,具体错误不会被
报出,调试的时候,但能看到Exception,, 只要存在网络互联,
就挺身而出,让你的程序不得运行。
原因是: 需要访问到网络,所以,在AndroidManifest.xml
中,需要进行如下配置:
在下面第三个页面permission中,选择“Add...”选择“uses
permission”,在右面name中选择
“android.permission.INTERNET” ;然后在
AndroidManifest.xml中会出现下面语句:
<uses-permission
android:name="android.permission.INTERNET" />
再次运行程序,就OK了。
2. 出现错误“The *** has not responding”:
原因有如下几种:服务器没有打开、
客户端要连接的IP不对、
Server和Client的端口不一致
、
客户端与服务器的接收和发送
没有一一对应,
导致等待超时,出现异常。
但是我的问题还为解决?
3。在学习Android的时候,偶尔会遇到异常。像要是遇到异常:“The application has stopped unexpectedly”的时候,首先去查看自己的代码是否有逻辑上的错误或者是漏洞,例如是不是使用了一个null对象。对象使用之前是否已经实例化。另外针对Android要特别注意,整个的程序中要关心的有三个部分:
业务逻辑--即逻辑上是否合理,代码部分是否正确。这个主要可以通过调试运行查看Log记录。
资源应用--Android的资源都放在了res文件下面,如Activity的布局一般都放在res/layout下面,并且一般是一个xml文件对应一个Activity。
AndroidManifest.xml--之前我在学习别人一个例子的时候就忽略了这个非常重要的东西,才导致了The application has stopped unexpectedly的发生。
相关文章推荐
- the application has stopped unexpected。please try again错误提示以及logcat不能打印解决
- the application has stopped unexpected。please try again
- the application has stopped unexpected。please try again
- Android跳转页面出现THe Application has stopped unexpectedly,please try again
- The application xxx has stopped unexpectedly. Please try again" in RELEASE mode
- android:The application has stopped unexpectedly, please try again.
- The application has stopped unexpectedly, please try again.
- 【Android】The application has stopped unexpectedly.Please try again.
- 【Android】The application has stopped unexpectedly.Please try again.
- the applicatein has stopped unexpected .please try again
- Application has stopped unexpectedly. Please try again." android解
- android提示错误: The process android.process.acore has stopped unexpectedly.Please try again
- 跳转出现错误 the application test has stopped unexpectedly 的解决
- zencart后台管理中选项名称和选项内容和属性控制页面出错解决办法 WARNING: An Error occurred, please refresh the page and try again
- win 2012 安装mysql 5.7.20 及报错 This application requires Visual Studio 2013 Redistributable. Please install the Redistributable then run this installer again 的解决办法
- 目前遇到的这个错误的“The application *** hans stopped unexpectedly. Please try again.”的原因。
- Android——The application study has stopped unexpectedly
- liunx 下scp出现 Permission denied, please try again 的解决办法
- "Setup has detected a pending system reboot from a previous install, Setup Cannot continue until the machine is rebooted. Please reboot the machine and run the installation again."问题的解决。
- mac 命令行 安装 需要管理员 权限“Please try running this command again as root/Administrator”的解决办法