Android Question B4XPages- Two Apps Using the same SQLite Database Not Showing Deletion in a Table

Mahares

Expert
Licensed User
Longtime User
I have 2 apps using the same SQLite database stored in File.DirRootExternal
1. On the 2nd app B4XMainPage I have a button to delete a record from a table. The record is definitely deleted, but the listview on the B4XPage is not updated. Where do I refresh the B4XPage to show the listview reflecting the deleted record.
2. When I launch the 1st app which uses the same database, its B4XPage which also has a listview does not update its listview either. How do I refresh the 1st app B4XPage’ s listview to reflect the deletion of the record that was made in the 2nd app.
In summary, both apps still show their respective listview with the record still there, although I confirmed the deletion from the table.
Thank you.
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
On the 2nd app B4XMainPage I have a button to delete a record from a table. The record is definitely deleted, but the listview on the B4XPage is not updated. Where do I refresh the B4XPage to show the listview reflecting the deleted record.
1. Why will the listview (who is using listview???) update itself? You need to remove the item from the list after you remove the item from the database.

2. You can use the Foreground event for this.
 
Upvote 0

Mahares

Expert
Licensed User
Longtime User
who is using listview???)
That is funny. That is the example that klaus edited and used a listview and I told him he will get in trouble with you. So, now both of us are in trouble with you. It is just for testing right now. It will be xClv when I overcome the B4XPages issues.
I will implement the changes and report back if I am still having trouble.
 
Upvote 0

klaus

Expert
Licensed User
Longtime User
Last edited:
Upvote 0
Top