Page 1 of 1

Set Property of component to Storage from JavaScript

Posted: Fri Apr 10, 2015 2:43 am
by Michael Droll

How do I set the property of a label to a read from storage in JavaScript?
Instead of doing this by the service success event. Having to do this for 25 labels 5 times each (125 Times) VIA the UI will take me forever (and wear out my finger!). Since my service is running a JS can this be done from the JS?

If so, how? An example of what the JS looks like would be awesome.


Set Property of component to Storage from JavaScript

Posted: Fri Apr 10, 2015 3:15 pm
by Serhii Kulibaba

Hello Michael,

You can use JS for setting label text from storage variable via JS:

var text = Apperyio.storage.variableName.get();
Apperyio("labelName").text(text);

where variableName - storage variable name
labelName - label name