文件名称:ListViewDemo
介绍说明--下载内容均来自于网络,请自行研究使用
要将数据库中的数据列表显示在屏幕上,我们要使用ListView这个控件,当用户从数据库中取出数据时,要将数据绑定到显示控件上,如何绑定呢,我们需要创建适配器进行绑定,创建适配器有两种方式:
第一种是用SimpleAdapter创建(要求绑定的数据是List<HashMap<String, Object>>数据类型)
第二种是用SimpleCursorAdapter创建(要求绑定的数据是Cursor数据类型)-To list the data is displayed on the screen, we want to use the ListView control, when a user retrieve data the , you want to bind data to the display control, how to bind it, we need to create an adapter bound , create an adapter in two ways:
The first is to use SimpleAdapter creation (requires data binding is List <HashMap <String, Object >> data types)
The second is to create SimpleCursorAdapter (requires data binding is Cursor data type)
第一种是用SimpleAdapter创建(要求绑定的数据是List<HashMap<String, Object>>数据类型)
第二种是用SimpleCursorAdapter创建(要求绑定的数据是Cursor数据类型)-To list the data is displayed on the screen, we want to use the ListView control, when a user retrieve data the , you want to bind data to the display control, how to bind it, we need to create an adapter bound , create an adapter in two ways:
The first is to use SimpleAdapter creation (requires data binding is List <HashMap <String, Object >> data types)
The second is to create SimpleCursorAdapter (requires data binding is Cursor data type)
(系统自动生成,下载前可以参看下载内容)
下载文件列表
ListViewDemo\.classpath
............\.project
............\.settings\org.eclipse.jdt.core.prefs
............\AndroidManifest.xml
............\bin\AndroidManifest.xml
............\...\classes\com\example\listviewdemo\BuildConfig.class
............\...\.......\...\.......\............\MainActivity.class
............\...\.......\...\.......\............\R$attr.class
............\...\.......\...\.......\............\R$dimen.class
............\...\.......\...\.......\............\R$drawable.class
............\...\.......\...\.......\............\R$id.class
............\...\.......\...\.......\............\R$layout.class
............\...\.......\...\.......\............\R$menu.class
............\...\.......\...\.......\............\R$string.class
............\...\.......\...\.......\............\R$style.class
............\...\.......\...\.......\............\R.class
............\...\classes.dex
............\...\dexedLibs\android-support-v4-97d09942220d462330bb68c12c43ae68.jar
............\...\.........\annotations-a3b60bc7da3d569fac85ba4700e66402.jar
............\...\jarlist.cache
............\...\ListViewDemo.apk
............\...\res\crunch\drawable-hdpi\ic_launcher.png
............\...\...\......\.........mdpi\ic_launcher.png
............\...\...\......\.........xhdpi\ic_launcher.png
............\...\...\......\..........xhdpi\ic_launcher.png
............\...\resources.ap_
............\gen\com\example\listviewdemo\BuildConfig.java
............\...\...\.......\............\R.java
............\ic_launcher-web.png
............\libs\android-support-v4.jar
............\proguard-project.txt
............\project.properties
............\res\drawable-hdpi\ic_launcher.png
............\...\.........mdpi\ic_launcher.png
............\...\.........xhdpi\ic_launcher.png
............\...\..........xhdpi\ic_launcher.png
............\...\layout\activity_main.xml
............\...\......\list_item.xml
............\...\menu\main.xml
............\...\values\dimens.xml
............\...\......\strings.xml
............\...\......\styles.xml
............\...\......-sw600dp\dimens.xml
............\...\.........720dp-land\dimens.xml
............\...\.......v11\styles.xml
............\...\.........4\styles.xml
............\src\com\example\listviewdemo\MainActivity.java
............\bin\classes\com\example\listviewdemo
............\...\.......\...\example
............\...\res\crunch\drawable-hdpi
............\...\...\......\drawable-mdpi
............\...\...\......\drawable-xhdpi
............\...\...\......\drawable-xxhdpi
............\gen\com\example\listviewdemo
............\src\com\example\listviewdemo
............\bin\classes\com
............\...\res\crunch
............\gen\com\example
............\src\com\example
............\bin\classes
............\...\dexedLibs
............\...\res
............\gen\com
............\res\drawable-hdpi
............\...\drawable-ldpi
............\...\drawable-mdpi
............\...\drawable-xhdpi
............\...\drawable-xxhdpi
............\...\layout
............\...\menu
............\...\values
............\...\values-sw600dp
............\...\values-sw720dp-land
............\...\values-v11
............\...\values-v14
............\src\com
............\.settings
............\assets
............\bin
............\gen
............\libs
............\res
............\src
ListViewDemo