private void Edit_Clicked(object sender, RoutedEventArgs e) { if (GatewayUserModel.Count == 0) { return; } int i = GatewayPivot.SelectedIndex; GatewayClient.EditUser(i, GatewayUserModel[i].Username, GatewayUserModel[i].Password); LoadUsers(); }