上一页 1 ··· 37 38 39 40 41 42 43 44 45 ··· 47 下一页
  2013年8月9日
摘要: 一、基本概念// 上下文对象private Context context;public FileService(Context context){super();this.context = context;}// 保存文件方法public void save(String filename, String fileContent) throws Exception{FileOutputStream fos = context.openFileOutput(filename, context.MODE_PRIVATE);fos.write(fileContent.getBytes(" 阅读全文
posted @ 2013-08-09 08:48 chen110xi 阅读(206) 评论(0) 推荐(0) 编辑
摘要: 一、错误级别Error > Warn > Info > Debug > Verbose(冗余)二、Android项目日志查看视图Console视图只能看项目的部署到模拟器上的信息,开发日志信息只能在LogCat视图上看。在LogCat视图上有按钮可以进行错误级别的筛选。比如点击Info按钮,会显示错误级别大于等于Info级别的日志信息。三、输出日志信息private final String tag = "xyLog";public void testLog1() throws Exception{String myname = "xy&q 阅读全文
posted @ 2013-08-09 08:47 chen110xi 阅读(363) 评论(0) 推荐(0) 编辑
摘要: 一、创建普通Android项目二、在AndroidManifest.xml添加两个配置引入测试相关类库配置单元测试框架启动装置三、编写测试代码package cn.xy.test;import junit.framework.Assert;import android.test.AndroidTestCase;import cn.xy.service.PersonService;public class TestClass extends AndroidTestCase{public void testSave() throws Exception{PersonService ps = new 阅读全文
posted @ 2013-08-09 08:43 chen110xi 阅读(207) 评论(0) 推荐(0) 编辑
摘要: 一、发现问题用户在执行一些如拨打电话、发送短信等关系用户隐私的功能时,Android需要出示权限,权限在AndroidManifest.xml中配置拨打电话的权限发送短信的权限那么这些权限信息如何得到呢?二、解决问题答案在Android的开发文档中。android-sdk-windows——>docs——>index.html——>references——>ANDROID——>Manifest.permission列出了很多字符串,你可以根据需要查找。http://blog.sina.com.cn/s/blog_67aaf44401015tbh.html 阅读全文
posted @ 2013-08-09 08:41 chen110xi 阅读(227) 评论(0) 推荐(0) 编辑
  2013年8月8日
摘要: 没有设置editText的inputtype属性,比如http://binuu.blog.51cto.com/801317/777459 阅读全文
posted @ 2013-08-08 23:14 chen110xi 阅读(200) 评论(0) 推荐(0) 编辑
  2013年8月6日
摘要: android SDK Manager更新不了,出现错误提示:"Failed to fetch URL..."!可以用以下办法解决:使用SDK Manager更新时出现问题 Failed to fetch URLhttps://dl-ssl.google.com/android/repository/repository-6.xml, reason: Connection tohttps://dl-ssl.google.comrefused Failed to fetch URLhttp://dl-ssl.google.com/android/repository/addo 阅读全文
posted @ 2013-08-06 09:38 chen110xi 阅读(206) 评论(0) 推荐(0) 编辑
  2013年8月5日
摘要: protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); TextView tv = (TextView)findViewById(R.id.textView); tv.setText("我的世界"); }如果创建项目后直接在AVD中运行,则显示乱码,最好的解决办法就是在状态栏里有个File Encoding的属性,默认是"Utf-8",把它改为" 阅读全文
posted @ 2013-08-05 23:32 chen110xi 阅读(870) 评论(0) 推荐(0) 编辑
摘要: AndroidStudio下载地址:https://developer.android.com/sdk/installing/studio.html#download如果你没有FQ或者不会FQ可以从百度网盘下载安装:android-studio-bundle-130.677228-windowsMac版本:android-studio-bundle-130.677228-mac感谢@iceskysl下面详细介绍一下安装过程及配置过程:(以windows 7为例)点解下载好的zip中的exe可执行文件,安装,可以自行设置安装目录安装好后点击studio.exe,如果不能打开,用记事本打开andr 阅读全文
posted @ 2013-08-05 10:11 chen110xi 阅读(421) 评论(0) 推荐(0) 编辑
  2013年3月26日
摘要: 單片機用altium designerKeilKeil C入門與使用http://www.vr.ncue.edu.tw/esa/a1001/ch03_20111007.pdf 阅读全文
posted @ 2013-03-26 23:37 chen110xi 阅读(208) 评论(0) 推荐(0) 编辑
  2012年11月17日
摘要: 只需7步,任何魔方6面皆可还原。非常强悍的技术贴啊,被魔方虐过的同学,快来研究! 首先,破解魔方,我们就要先了解它的结构,魔方共6色6面,每面又分为中央块(最中间的块6个)、角块(4角的块8个)和边块(4条边中间的块12个)。其中中央块只有1个面,他们是固定的结构,所以中央是红色的块,那么其他的红色都要向这个面集中。而且红色的中央块对面永远是橙色中央块(国际标准是这么规定的)。而边块有2个面2个颜色,角块则有3个面3个颜色。 接下来,我们将每个面都用字母代表。 然后破解功略里会用字母来说明要转动的1层或1面,以及方向:例如:R(代表右面顺时针转90度... 阅读全文
posted @ 2012-11-17 18:27 chen110xi 阅读(39337) 评论(1) 推荐(0) 编辑
上一页 1 ··· 37 38 39 40 41 42 43 44 45 ··· 47 下一页