Hybrid Android App with SQLite

      Comments Off on Hybrid Android App with SQLite

Google Add

This article is written to help programming beginners to program a simple android app, using Cordova, html, Javascript and CSS.

The keywords are

  • search for patterns and pratices,
  • re-use pattern and/or code,
  • add or change code to build your app  in step-wise refinement

I google-searched on phrases of JQuery and SQLite example/tutorial and locate a simple example at http://jsfiddle.net/mfirdaus/2vhA6/.

The next step was to create the html file and js file for this example and to upload to at website to verify the code is working.


Next, I added a simeple CSS to make it look nicer. I searched on w3school.com and found this page. So I created a simple style.css file. Below is the screen image of the second prototype.


Next, I proceeded to create an android hybrid app with Cordova. If you have not gone through the first tutorial of Cordova, please visit this page on cordova.apached.org.

First I created a new project with cordova command in a command console of my computer.

Secondly, I added Android platform to this project, then I built the app.

Next, I started the emulator and verified that the app worked.

Then, I copied the index.html, dbprocess.js, and style.css to the www sub-folder of the project. Next I rebuilt the app. and test it with the emulator