PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WINDEV Mobile 2024 → Strange Issue in Android only
Strange Issue in Android only
Débuté par Jim, 07 juin 2019 17:23 - 4 réponses
Posté le 07 juin 2019 - 17:23
I have an app that will connect to one of our many different units and download the onboard logs into a buffer. Then a procedure parses the data and displays it in a table.

If the data is downloaded once, the data table is filled in under 2 seconds. If the user decides to download them again for some reason, the procedure takes quite a while to run (20 seconds) and populate the data into the table. A couple of our units have 4000 records, and these take over a minute the second time.
I cannot see a reason for this big delay. It makes the app appear to have frozen, when it hasn't. In the emulator and IPhone the behavior does not happen, only on an Android device.
I have tried three different devices, two phones and a tablet.

Any suggestions?

Jim
Posté le 08 juin 2019 - 03:42
Have you tried to manage that process on a completely different thread than the main UI thread ? that is what i would do..
Posté le 10 juin 2019 - 19:42
Thanks, I am going to try that.
The problem actually got worse after trying to make the Android version more like the IOS version.
There is a clue in there somewhere.

Previously I have the download log on its own window. When changing to different units it was fine the first download for a new unit. In IOS I had to change it to make the entire app in one window. When I changed the Android app to all one window, switching from unit to unit still has the big delay even the first time on a unit unless the app was just opened.

I have not used threads, but the boss has. I think we can solve this.


Thanks

Jim
Posté le 14 juin 2019 - 17:53
Well I am happy to report that this worked. Why I don't know, but it did.
Thanks

Jim
Posté le 16 juin 2019 - 14:01
I am happy that my advice helped you solve the issue, i wish you the best in your development projects.