B4J Question Is it possible to know if a B4XTable has been edited?

Mikelgiles

Active Member
Licensed User
Longtime User
I have looked at the properties of B4XTable but didn't see anything. I have many locations of code that does a refresh and saving to a CSV file when needed. I would like to move this process to a SUB and have the sub know if the data had changed and only do the refresh and save if the database has been changed.
 

DonManfred

Expert
Licensed User
Longtime User
You can set a flag when you edit a value.

It is YOU who edit anything. So you should know when the data changes
 
Upvote 0

MicroDrie

Well-Known Member
Licensed User
Longtime User
To detect whether the user of your software has changed anything, you can calculate a hash code on your loaded CSV data and compare it to detect whether or not the table has modified content. A less burdensome choice is an edit button / menu option and then assume that use of de button / menu option automatically leads to the rewriting of the data that has been or is not changed in order to limit the required resources. In that case if the files are stored centrally, you can make the choose to carry out the hascode check there and simply ignore unchanged CSV data.
 
Upvote 0
Top