Android: Develop Data Entry and Export info to Text File

Fernando Roque

Play Speed
  • 0.5x
  • 1x (Normal)
  • 1.25x
  • 1.5x
  • 2x
9 Lessons (2h 4m)
    • 1. Promotion: Data​ ​ Capture​ ​ and​ ​ Store​ ​ information​ ​ in​ ​ local​ ​ Android​ ​ DataBase Expo

    • 2. Introduction Android DataEntry: User Layout, Database and generate CSV text file

    • 3. Android User Form Layout: RowLayout for Text, DataEntry fields and Buttons

    • 4. Allocate Buttons in TableRows. On Click Event to execute actions

    • 5. Generate CSV-Text File from Android Database

    • 6. Database: Create Database and Tables

    • 7. Select and Insert Statements of Android Database

    • 8. Project: Data Entry to Database and Exporting CSV-TEXT File. Source Code on Project Section

    • 9. Text, Edit text and Buttons with on click actions to Insert in database and generate CSV File


About This Class


The general structure of App is explained:
a) MainActivity Class where the layout of user screen is defined.
b) DatabaseHandler Class.  Creation of database, insert and select 
   queries.  How Cursor works on android database.
c) Generation of the CSV file.
The intruction explains how important is to understand the layout
of the user screen to allocate space on each table and row for
Text and Data Entry fields.  Also for buttons and the On Click 
event to execute an action like:
a) Insert data entry to the database.
b) Generate the text CSV file.

The souce code  and PDF with explanation is included in the section two of the course.


a) Structure of the App
b) TableLayout to Display Titles, Input Fields and Buttons.
c) Properties for Rows on Table Layouts to Display Text, Edit Fields and Buttons.
Structure concept to allocate Text, Edit and Button Fields inside the Rows of the
d) Actions to allocate each Field on the Rows and each Row inside the Table
e) Create Database Handler Class
f) Initialization Methods of the DatabaseHandler.
g) Insert and Select Statements in the Database
h) Code for Function SelectData() on the MainActivity to get the results of the query
from the Database.
i) Functions and Statements to generate CSV file from Database Query.
j) Display and Orientation settings Initialization
k) Run and Test Code
l) Export the data from database to CSV file
m) Exercise to build all the Pieces Together

The source code packed in the file has the structure to be
imported in the Eclipse with Android Plug In IDE. The version used to compile the
source code is Eclipse JUNO. If you are using another version or IDE, the source files are located on path: Inventory/src/com/com/example2/ex2 : and