Ticket Created
over 4 years ago

WERETECH-11175

set/getProperty deprecate on sdk 4?

In current doc something has changed!!

Previous information: some function (e.g. deleteProperty) was planned to remove but not set/get.

My app run well and there are values in sim Application.AppBase.Data.

So, is documentation correct?

I have some strange app behaviour on sim:

- settings don't change

- memory peaks

- console  message "Unable to serialize app data"

- resetting settings to default

can be connected with any changes in sdk 4?

Parents
  • o time I have enough memory (especially you suggest class, members and consumption memory too)  I prefer not to mix in jungle, my solution:

        function setPrp(k, v)
        {
            if(APP has :Storage)
            {
                APP.Storage.setValue(k, v);
            }else
            {
                APP.getApp().setProperty(k, v);
            }
        }
        
        function getPrp(k)
        {
            if(APP has :Storage)
            {
                return APP.Storage.getValue(k);
            }else
            {
                return APP.getApp().getProperty(k);
            }
        }

Comment
  • o time I have enough memory (especially you suggest class, members and consumption memory too)  I prefer not to mix in jungle, my solution:

        function setPrp(k, v)
        {
            if(APP has :Storage)
            {
                APP.Storage.setValue(k, v);
            }else
            {
                APP.getApp().setProperty(k, v);
            }
        }
        
        function getPrp(k)
        {
            if(APP has :Storage)
            {
                return APP.Storage.getValue(k);
            }else
            {
                return APP.getApp().getProperty(k);
            }
        }

Children
No Data