Android
MeCoco99
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
EditText.getText()返回值问题
TextView的getText()方法,返回类型是CharSequence,如果判断是否为空的话,只要equals.("")或者toString.isEmpty()即可,因为String是CharSequence的实现类,可以直接equals,而且源码中已经为其默认赋值为“”,没有为null的时候。 EditText的getText()方法,返回类型是Editable,如果判断是否为空,不能==...转载 2019-04-13 00:19:44 · 2955 阅读 · 0 评论 -
Your project path contains non-ASCII characters.
ERROR: Your project path contains non-ASCII characters. This will most likely cause the build to fail on Windows. Please move your project to a different directory. See http://b.android.com/95744 for ...原创 2019-04-09 22:50:01 · 239 阅读 · 0 评论 -
运行Android Studio时,出现error while installing apks
解决办法:file–>Settings–>Build,Execuion,Deployment–>Instant Run 然后把最上面的Enable Instant Run to 那一项去掉勾选就行了原创 2019-04-13 14:11:04 · 2804 阅读 · 2 评论 -
Android学习笔记:Android开发时要使用HttpClient,要如何导入它的包呢?
在Android Studio,打开自己的Android项目文件,在Gradle Scripts选项那里找到build.gradle(Module:)。 打开它,在Android{********}大括号中添加这句代码:useLibrary ‘org.apache.http.legacy’。例如: 写好之后就可以在Java代码中倒入要用的类了。 ...原创 2019-06-26 15:29:54 · 3309 阅读 · 0 评论 -
Caused by: android.view.InflateException: Binary XML file line #10: Error inflating class ImageView
在写ImageView的时候,出现了题目这样的问题,因为我是导入别人的项目,但是我看他写的属性都很平常,没什么问题的,代码如下: <ImageView android:id="@+id/imageView1" android:layout_width="match_parent" android:layout_height="wrap_content" and...原创 2019-07-08 17:39:27 · 798 阅读 · 1 评论 -
《Android学习笔记》:Infalte()方法的理解
Inflate()方法有这样两种形式: inflate(int resource, ViewGroup root) inflate(int resource, ViewGroup root, boolean attachToRoot) 其中,resource是我们要加载的布局文件的id,root是指定布局要加载到哪一个容器中,attachToRoot待会详细说。 定义parent.xml和chil...原创 2019-07-21 11:46:02 · 328 阅读 · 0 评论
分享