Share My Creation Shopping List Database

This is a shopping list database using SQlite. It was supposed to be simple but ended up over 600 lines.

It has add,update and delete functions. I added a help screen because there were so many buttons.

I based this program on the Family Meds application by TREMAR1. I thank him for the ideas and some code.

I added several functions including portrait and landscape formatting. I also use selections based on a checkbox.

This should help users programming a database.

Write with questions and bugs.
 

Attachments

  • sql-test1.zip
    15.1 KB · Views: 1,992
  • sample1.jpg
    23.2 KB · Views: 11,212
  • sample2.jpg
    26.2 KB · Views: 2,027
  • sample3.jpg
    39.2 KB · Views: 1,884

aklisiewicz

Active Member
Licensed User
Longtime User
Many thanks for creating this example,... at least something to start with.
I have few questions regarding this App.
- does this SQLite table uses any PrimaryKeys (I do not se any, and I'm pretty sure that any good dB design requires at least one Pk for every table)

- If I add new record I would like to populate a field frmo the spiner, but I would want the spiner lookup in the existing (another) table. How would I do this ?

- scroling records with the finger on a device makes sort of unpleasant behavior making screen dark (at least on my HTC phone). Can this be fixed ?

- where is the database stored on the phone ? can I copy it from the phone to the PC and vice versa ?

Arthur
 

Merlot2309

Active Member
Licensed User
Longtime User
Ok Arthur,

What do you want to say with those dots?

If you prefer a spreaded bed (sorry, translated Dutch expression and don't bother to have a search) this is not the correct approach.
First of all: there are some forum topic, examples, etc. about working with databases.

Second: SQL(ite) has it's own commands. I would like to advice you to have a look at the B4A examples and then go to SQL/SQLite info pages on Internet.
B4A can handle all the SQL(ite) queries and commands.

If you want to do some programming, start searching, try to understand the code and try something on your one.
i learn most from my mistakes - in coding - and I like it.
It makes me feel good when I achieved something on my own and that is what makes writing code soooooooo nice.

Honoustly: you don't know me - I don't know you but I do not appreciate the tone you showed in this community so far.

Helen.
 

aklisiewicz

Active Member
Licensed User
Longtime User
 
Last edited:

Merlot2309

Active Member
Licensed User
Longtime User
Arthur,

Ok, thanks for your reply - I'm not developing professional anymore and have all the time of the world.


1. The database is stored in the root of the SD-card in the Android dir -> Data -> [Project name] -> Files.
2. I always use a black background with white font, so never encountered this. I find this much better for the eyes, ha, ha.
3. The Primery Key is set in the Database itself, as you most probably know.
You can use SQL.ExecQuery("REINDEX [Table name]") to keep it clean.
4. I don't understand your question about the new record

Helen.
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…