private void ExecuteNavigatedTo(NavigateTo obj)
        {
            if (obj.Reload == true)
            {
                getChatroom();
            }


            if (obj.Name == "loaded")
            {
                Type view = (Type)obj.View;
                if (view == (typeof(VindRitChat)))
                {
                    Loaded();
                }
            }

            switch (obj.Name)
            {
                case "newComment":
                    getChatroom();



                    break;
                default:
                    break;
            }
        }
 private void ExecuteNavigatedTo(NavigateTo obj)
 {
     if (obj.Name == "loaded")
     {
         Type view = (Type)obj.View;
         if (view == (typeof(FeestjesOverzicht)))
         {
             Loaded();
         }
     }
 }
 private void ExecuteNavigatedTo(NavigateTo obj)
 {
     if (obj.Name == "loaded")
     {
         Type view = (Type)obj.View;
         if (view == (typeof(Profiel)))
         {
             Loaded();
         }
     }
 }
        private void ExecuteNavigatedTo(NavigateTo obj)
        {
            if (obj.Name == "loaded")
            {
                Type view = (Type)obj.View;
                if (view == (typeof(VeranderWachtwoord)))
                {
                    Loaded();
                }

              

            }
        }
        private void ExecuteNavigatedTo(NavigateTo obj)
        {

            if (obj.Reload==true)
            {
                Type view = (Type)obj.View;
                if (view == (typeof(VindRitFilter)))
                {
                    Loaded();
                }
            }
        }
        //Methods

        #region navigate to
        private async void ExecuteNavigatedTo(NavigateTo obj)
        {
            if (obj.Name == "loaded")
            {
                Type view = (Type)obj.View;
                if (view == typeof(VindRit))
                {
                    //loaded
                    Loaded();
                }
            }
            if (obj.Reload == true)
            {
                Type view = (Type)obj.View;
                if (view == typeof(VindRit))
                {
                    this.VisibleFind = Visibility.Visible;
                    //loaded
                    Loaded();
                }
            }

            if (obj.Name != null && obj.Name != "")
            {
                switch (obj.Name)
                {
                    case "trip_location":
                        if (MainViewVM.CurrentTrip != null)
                        {
#pragma warning disable CS1998 // Async method lacks 'await' operators and will run synchronously
                            await CoreApplication.MainView.CoreWindow.Dispatcher.RunAsync(CoreDispatcherPriority.Normal, async () =>
                            {
                                trip_location();
                            });
#pragma warning restore CS1998 // Async method lacks 'await' operators and will run synchronously
                        }

                        break;
                    case "rating_dialog":
                        Bobs_Parties item = JsonConvert.DeserializeObject<Bobs_Parties>(obj.Data.ToString());
                        RatingDialog(item);
                        break;
                    case "find_bob":
                        find_bob((bool)obj.Result);
                        break;
                    case "get_trip":
                        await GetCurrentTrip();
                        
                        break;
                    case "trip_location:reload":
                        Users_Destinations dest = Task.FromResult<Users_Destinations>(await DestinationRepository.GetDestinationById(MainViewVM.CurrentTrip.Destinations_ID)).Result;

                        //instellen voor timer, niet gebruiken in filter
                        VindRitFilterVM.SelectedDestination = dest;
                        if (VindRitFilterVM.SelectedDestination != null)
                        {
                            VindRitVM.SelectedParty = await PartyRepository.GetPartyById(MainViewVM.CurrentTrip.Party_ID);
                            this.EnableFind = false;
                         
                            RaiseAll();
                            StartTripLocationTimer();
                           
                        }
                        RaiseAll();
                        break;
                    case "map_reload":
                        //map reload
                        break;
                    default:
                        break;
                }
            }
        }
        private async void ExecuteNavigatedTo(NavigateTo obj)
        {
            if (obj.Name == "loaded")
            {
                Type view = (Type)obj.View;
                if (view == typeof(VindRitBob))
                {
                    //loaded
                    Loaded();
                }
            }
            if (obj.Reload == true)
            {
                Type view = (Type)obj.View;
                if (view == typeof(VindRitBob))
                {
                    //loaded
                    Loaded();
                }
            }

            if (obj.Name != null && obj.Name != "")
            {
                switch (obj.Name)
                {
                    case "bob_accepted":
                        float id = float.Parse(obj.Data.ToString());
                        bob_accepted((bool)obj.Result, id);
                        break;
                    case "newtrip_bob":
#pragma warning disable CS1998 // Async method lacks 'await' operators and will run synchronously
                        await CoreApplication.MainView.CoreWindow.Dispatcher.RunAsync(CoreDispatcherPriority.Normal, async () =>
                        {
                            await UserRepository.PostPoint(3);

                            var data = (Trip)obj.Data;
                            data.StatusID = 2;
                            SetStatus(2);

                            this.Loading = false;
                            RaiseAll();

                            newtrip_bob(data);
                        });
#pragma warning restore CS1998 // Async method lacks 'await' operators and will run synchronously
                        break;
                    case "trip_location:reload":
                        Users_Destinations dest = Task.FromResult<Users_Destinations>(await DestinationRepository.GetDestinationById(MainViewVM.CurrentTrip.Destinations_ID)).Result;

                        //instellen voor timer, niet gebruiken in filter
                        VindRitFilterVM.SelectedDestination = dest;
                        if (VindRitFilterVM.SelectedDestination != null)
                        {
                            StartTripLocationTimer();
                        }
                        RaiseAll();
                        break;
                    case "map_reload":
                        //map reload
                        break;
                    default:
                        break;
                }
            }
        }
 private async void ExecuteNavigatedTo(NavigateTo obj)
 {
     if (obj.Name == "loaded")
     {
         Type view = (Type)obj.View;
         if (view == (typeof(MijnRitten)))
         {
             Loaded();
         }
     }
 }
 private async void ExecuteNavigatedTo(NavigateTo obj)
 {
     if (obj.Name == "loaded")
     {
         Type view = (Type)obj.View;
         if (view == typeof(MainView))
         {
             //loaded
             Loaded();
         }
     }
     if (obj.Reload == true)
     {
         Type view = (Type)obj.View;
         if (view == typeof(MainView))
         {
             //loaded
             Loaded();
         }
     }
 }
        private void ExecuteNavigatedTo(NavigateTo obj)
        {
            if (obj.Name == "loaded")
            {
                Type view = (Type)obj.View;
                if (view == (typeof(Bestemmingen)))
                {
                    Loaded();
                }

                Type view2 = (Type)obj.View;
                if (view2 == (typeof(Bestemmingen_Nieuw)))
                {
                    LoadedNew();
                }

            }
        }