自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

xiaowanggedege的专栏

总结、分享、成长、A lifelong learner

  • 博客(16)
  • 收藏
  • 关注

原创 Android-小项目之迷你英文词典-使用existing sqlite database-github第三库android-sqlite-asset-helper

将已有的词典数据库文件,用到项目中谷歌搜索“android existing sqlite database”http://stackoverflow.com/questions/1951805/how-to-access-an-existing-sqlite-database-in-android通常来说,SQLiteDatabase db = SQLiteDatabase.

2013-11-30 23:11:28 4422 1

原创 Android使用SharedPreferences保存读取文件,BroadcastReceiver广播模拟IP拨号

File: MainActivity.java将 输入框里的 IP号码保存到  SharedPreferences 指定的 config.xml文件中,再将数据回显出来。package com.jiangge.ipdial;import android.os.Bundle;import android.app.Activity;import android.content.Shar

2013-11-30 17:38:27 2464

原创 Android--检测用户的网络情况netWorkInfo-Dialog-intent跳转到系统网络设置界面

检测用户的网络情况,若网络不可用,则弹出对话框,点击“确定”后跳转到系统网络设置的界面--logCat里查看cmp=com.android.settings/.Settings//检测用户的网络情况,若网络不可用,则弹出对话框,点击“确定”后跳转到系统网络设置的界面--logCat里查看cmp=com.android.settings/.Settings ConnectivityMan

2013-11-29 23:53:32 2666

原创 Android--ListView和SimpleAdapter

一、File:MainActivity.javapackage com.jiangge.simpleadapterdemo;import java.util.ArrayList;import java.util.HashMap;import java.util.List;import java.util.Map;import android.app.Activity;impor

2013-11-26 22:14:18 1275

原创 Android--ListView和ArrayAdapter例子

File: MainActivity.javapackage com.jiangge.arrayadapterdemo;import android.app.Activity;import android.os.Bundle;import android.widget.ArrayAdapter;import android.widget.ListView;public class

2013-11-26 22:13:50 1435

原创 Android-SharedPreferences保存数据,读取数据

SharedPreferences 以 key-value键值对的形式保存数据,不需要指定文件后缀名,后缀自动设置为 *.xml,如下例的 config,最终为 config.xml一、保存数据//存数据public static boolean saveUserInfo(Context context, String username, String password){ Sha

2013-11-25 21:36:52 2756

原创 Android--SDcard permission权限,mounted挂载,Available space可用空间,TotalSpace总空间

在Manifest.xml文件中,写外部设备写权限:如果是用得模拟器,要确保创建AVD时,已经为SDcard分配了空间。判断SDcard有没有挂载,若没有挂载,则弹提示:if(!Environment.MEDIA_MOUNTED.equals(Environment.getExternalStorageState())){ Toast.makeText(this, "E

2013-11-24 22:45:53 2561

原创 Android--模拟登陆用户名密码,使用File或openFileOutput保存文件

一、File:xml布局文件<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout

2013-11-24 21:12:38 2062 1

原创 Android使用Intent发送短信SMS

两种发送短信方式:方法一、使用Intent发送短信 Intent smsIntent = new Intent(); smsIntent.setAction(Intent.ACTION_VIEW); smsIntent.putExtra("sms_body", "默认内容哈哈。"); smsIntent.setType("vnd.android-dir/mms-sms");

2013-11-24 17:35:40 5780

原创 Android -- make a phone call using Intent--使用意图拨打电话

一、File:package com.jiangge.phonedeom;import android.app.Activity;import android.content.Intent;import android.net.Uri;import android.os.Bundle;import android.view.View;import android.view.Vie

2013-11-24 17:35:01 1488

原创 Android--eclipse DDMS导出文件失败--android Failed to push the item

报错信息:Failed to push selection: Local path doesn't exist.android Failed to push the item解决方法StackOverflow:Eclipse Windows -> Preferences -> Android -> DDMS

2013-11-24 17:34:21 9199 1

原创 How To Create Directory In Java--创建单个目录,多个目录(子目录)

How To Create Directory In Java--创建单个目录,多个目录(子目录)new File("C:\\Directory1").mkdir(); //创建单个目录new File("C:\\Directory2\\Sub2\\Sub-Sub2").mkdirs() //创建多个目录,子目录如何创建成功,则mkdir()返回值为 true

2013-11-20 23:52:03 3696

原创 Android-01-渐变动画效果,展示启动屏,取消标题,取消状态栏,也即全屏

package com.jiangge.yiweibo;import android.os.Bundle;import android.app.Activity;import android.content.Intent;import android.view.Window;import android.view.WindowManager;import android.view.a

2013-11-20 23:48:20 1937

原创 Android百度地图之显示地图

添加地图显示一、在百度官网下载相关的SDK(网址:http://developer.baidu.com/map/sdkandev-download.htm)解压下载好的BaiduMap_AndroidSDK_v2.1.3_Sample文件把BaiduMap_AndroidSDK_v2.1.3_Sample中的 libs 中的文件全部复制到 Project 中

2013-11-18 21:30:33 1811 1

原创 Using an Intent to make a photo--Android使用Intent拍照

使用Intent 调用系统自带的相机App进行拍照。package com.jiangge.cameraintentdemo;import android.app.Activity;import android.content.Intent;import android.graphics.Bitmap;import android.os.Bundle;impor

2013-11-07 22:45:06 1610

原创 Android AutoCompleteTextView

AutoCompleteTextView ,自动补全(自动完成、自动提示),常见于搜索时的自动补全,例如谷歌搜索,电子词典File: layout/activity_main.xml<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://sc

2013-11-04 21:03:59 1116 1

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除