Contact Phone Book

Hello all,

I have a phonebook. I just want to add two Listpicker. One to select contact by name and the second one to select contact by number.
Please help me.
Thank you all.

Phonebook.aia (4.5 KB)

If you are asking for help, I recommend you to make it as easy for others to be able to help you ...
You probably will get more feedback then...

which means in your case post a screenshot of your relevant blocks...

To download the aia file, upload it to App Inventor, open it, do some bug hunting for you, etc... this takes time, and most people will not do that...
Thank you.

Taifun


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by Taifun.

I am sorry Taifun,

These are my blocks

Thank you for give me the opportunity to help me.

Hello Taifun,

Is there another way easier than this to save contact names and number in excel sheet then we put them in listpicker separately.

Thank you.

a solution could be to store the names and phone numbers in a Google Spreadsheet and use the Visualization API to query the table, see an example here App Inventor Tutorials and Examples: Google Spreadsheet Database | Pura Vida Apps

lets assume, you stored the names in column A and the phone numbers in column B
to get a list of the names alphabetically you would use this query
select A order by A
to get a list of the phone number you would use this query
select B order by B

Taifun

This is a little difficult. I mean if there is something else much easier than this:) please.

Thank you Taifun.

Does it have to be stored in a spreadsheet ?

We have cloudDB, tinywebDB, Firebase, others....

If you store your contacts in a table (list of lists) under a single TinyDB tag, you can filter it like this ...

Alternatively, you can make two TinyDB Namespaces,
indexed by name or phone number respectively,
and populate List Picker Elements for a Name Picker
and Phone picker from their respective TagLists.

This would require double maintenance, having to add a name/phone in one TinyDB
and a Phone/Name in the other TinyDB.

Once the contact is loaded, TinyDB does all the work for you.

Here is a quick edit of your project with both TinyDBs.
I also turned on the filter bar for your names List Picker, so you get the search for free ...

btnSave Click Phonebook_ABG.aia (5.0 KB)

That is a very wonderful.

I make two TinyDB Namespaces. I didn't know about it before.

Thank you very much ABG.
Have a nice day and good luck.