WebExpress.TabView.LoadSuggestions C# (CSharp) Method

LoadSuggestions() private method

private LoadSuggestions ( ) : Task
return Task
        private async Task LoadSuggestions()
        {
            await Dispatcher.BeginInvoke((Action) (() =>
            {
                try
                {

                    MagicBox.Clear();
                    allItems1.Clear();

                    if (System.IO.File.Exists(StaticDeclarations.Historypath))
                    {
                        string readFile = System.IO.File.ReadAllText(StaticDeclarations.Historypath);
                        dynamic json = JsonConvert.DeserializeObject(readFile);
                        foreach (dynamic item in json)
                        {
                                MagicBox.AddSuggestion(Convert.ToString(item.Title), Convert.ToString(item.Url), mainWindow);
                                allItems1.Add(Convert.ToString(item.Url) + "*" + Convert.ToString(item.Title));
                        }
                    }
                }
                catch (Exception ex)
                {
                    Console.WriteLine("Load suggestions error: " + ex.Message + " " + ex.Data);
                }
            }));
        }