| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 | using InABox.Mobile;using System;using System.Collections.Generic;using System.Text;using System.Threading;using System.Threading.Tasks;using Xamarin.Forms;namespace comal.timesheets{    public static class NotifyMobileChanges    {        public static string Notifiy()        {            RemoveOldProperties();            string latestChanges = "";            List<string> changes = new List<string>                {                "- Stability improvements to connections"                };            foreach (string s in changes)            {                latestChanges = s + System.Environment.NewLine + latestChanges;            }            if (App.Current.Properties.ContainsKey("NotifiedOfChanges" + MobileUtils.AppVersion.InstalledVersionNumber))                return "";            else            {                App.Current.Properties.Add("NotifiedOfChanges" + MobileUtils.AppVersion.InstalledVersionNumber, "True");                return latestChanges;            }                    }        private static void RemoveOldProperties()        {            if (App.Current.Properties.Count > 0)            {                List<string> toDelete = new List<string>();                foreach (string s in App.Current.Properties.Keys)                {                    if (s.Contains("NotifiedOfChanges"))                    {                        if (!s.Equals("NotifiedOfChanges" + MobileUtils.AppVersion.InstalledVersionNumber))                        {                            toDelete.Add(s);                        }                    }                }                foreach (string s in toDelete)                {                    App.Current.Properties.Remove(s);                }            }        }    }}
 |