private async void Button_Click(object sender, RoutedEventArgs e) { if (!string.IsNullOrEmpty(viewModel.MasterPassword) && !String.IsNullOrEmpty(viewModel.UserName)) { viewModel.EditIsEnabled = false; StatusBarProgressIndicator statusBarIndicator = StatusBar.GetForCurrentView().ProgressIndicator; StatusBar.GetForCurrentView().ForegroundColor = Windows.UI.Colors.White; statusBarIndicator.Text = "Master Key is derived..."; await statusBarIndicator.ShowAsync(); await MasterKey.CreateMasterKeyAsync(viewModel.MasterPassword, viewModel.UserName); StatusBar.GetForCurrentView().BackgroundColor = Windows.UI.Colors.Green; statusBarIndicator.Text = "Derivation complete! Login successful"; Frame.Navigate(typeof(SitePage), viewModel.UserName); } }