cancel
Showing results for 
Search instead for 
Did you mean: 

MDK Mobile Application - How to keep variables between synchronizations

Radek_Uhlir
Explorer
0 Kudos

I am storing some variables in

pageProxy.getAppClientData().<variable> = <some value>;

Application client data are being cleared during synchronization. Where should I store variables, if still need them after synchronization? But I do not need them when the user re-opens the mobile application.
Should I use appSettingsModule, even if it is persistent?

context.nativescript.appSettingsModule.setString(<key>, <value>);

 

bill_froelich
Product and Topic Expert
Product and Topic Expert
0 Kudos
To clarify, by synchronization you mean upload/download of offline data or are you referring to accepting a new app version from App Update?
bill_froelich
Product and Topic Expert
Product and Topic Expert
0 Kudos
Also please confirm what platform and mdk version you are working with?
Radek_Uhlir
Explorer
0 Kudos
Sorry, totally my mistake. Application data are not changed by synchronization. In my case, synchronization triggers redraw multiple times, and redraw calls my functions and that function overwrites my data.

Accepted Solutions (0)

Answers (0)