Hello everyone
I am very new to App Inventor and need some guidance.
I'm building an app to keep track of interruptions of the workflow. And I am building it like a multiple stopwatches that do something like lap times, where every lap is an interruption.
I managed to make the stopwatches to run and stop - for the first interruption. But when I press again the start button, the time resets - which is not what I need. I need that it runs continously.
Also, at the end of the day I need to sum up all the timers, of the laps - to put it simple, and make a report with these values, of each and every lap times.
While I've managed to make the timers, to count how many interruptions (how many times each START button was pressed), I am missing the problems presented earlier.
Also managed to save each value in TinyDB but don't know how to put them in some sort of report: csv or text, and how to retrieve such report.
Thank you in advance for any type of help or suggestions.
You need to rename your procedure to something like 'NN' to distinguish it from other procedures and to provide a hint as to what it does (make a 2 digit number).
You are right, getting rid of mills should ease the problems when need to sum up the time. About the third button, for matter of space I think I will do a "when button longclick do" to give it the third function, of resume.
What I think is considering duration in terms of Millis would be good as base unit, while saving into TinyDB and reterving the same. Since, milliseconds will provide ease to expends to hours, muniets and seconds and vice versa. Instead of Millis you can take seconds as base uinit for your duration. It also help you to sumup the time
At least a few things / questions need to be clarified in advance:
How long are the timers (stopwatches) needed (seconds, minutes, hours)? The question is relevant to knowing whether the timer(s) must also be running in the background (since running in the background in Doze mode causes the timer to stop working).
What exactly is the goal? Are only the split times needed and can the stopwatches continue or should they pause/stop?
What should happen with the split times / total running times at the end? What are these needed for?
The amount of overall stops shouldn't exceed 2 hours. All the timers, all the stops on the work flow, should not exceed 2 hours.
I need split times so the stopwatches need to stop and, at the end of the day, I need the sum of all those split times (btw - thanks for the proper name).
Also, when the day ends I need a detailed report of those split times and how many are.
In order for this to work on all devices (Android > 5, Doze mode) it must remain in the foreground during this period (i.e. not go into idle mode or you must use a Foreground service).
Test my aia and adapt it to your needs and then come up with further questions if necessary.