如何使用SQLite数据库在我的Andr​​iod活动? [英] How can i use Sqlite database in my andriod activity?

查看:143
本文介绍了如何使用SQLite数据库在我的Andr​​iod活动?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用的SQLite数据库中创建一个示例应用程序可惜我不是在SQLite数据库的概念熟悉。我有以下要求,

I'm creating a sample application using sqlite database unfortunately I'm not familiar in sqlite database concepts. I have the following requirements,


  1. 我有一个名为作为quotes.db SQLite数据库。具有这两个领域的数据库数量和行情。存储在资产文件夹中。

  2. 在我的活动我有两个字段一个是EditText上,另一个是按钮。​​

  3. 当用户的EditText输入值(数字),然后单击该按钮。现在我显示存储在数据库中的相应的报价。

如果有任何一个样本code相似,这个片段后亲切。先谢谢了。

if any one having sample code snippet similar to this kindly post. Thanks in advance.

推荐答案

您可以遵循的本教程这是一本介绍Android应用程序,特别是对数据库中的Andr​​oid。

You can follow this tutorial which is an introduction to Android apps and especially to databases in Android.

Quting网站:

这是写记事本应用本教程给你一个动手
  介绍了Android框架和用于构建的工具
  它的应用程序。从preconfigured项目文件出发,
  引导您完成开发一个简单的记事本的过程
  应用并提供了如何建立具体的例子
  项目,开发应用程序逻辑和用户界面,然后
  编译并运行应用程序。

This tutorial on writing a notepad application gives you a "hands-on" introduction to the Android framework and the tools you use to build applications on it. Starting from a preconfigured project file, it guides you through the process of developing a simple notepad application and provides concrete examples of how to set up the project, develop the application logic and user interface, and then compile and run the application.

这篇关于如何使用SQLite数据库在我的Andr​​iod活动?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆