private async void RangeValue(object sender, SelectionChangedEventArgs e) { switch (e.AddedItems[0].ToString()) { case "Diario": mes.Visibility = Visibility.Collapsed; año.Visibility = Visibility.Collapsed; calcular.Visibility = Visibility.Collapsed; range = DateTime.Today.ToString("dddd, dd MMMM yyyy"); Load(); await Calculo.AnimateHeightAsync(0, 300, null); ExcelButton.IsEnabled = true; break; case "Mensual": mes.Visibility = Visibility.Visible; año.Visibility = Visibility.Visible; año.SelectedDate = DateTime.Today; mes.Visibility = Visibility.Visible; calcular.Visibility = Visibility.Visible; //range = DateTime.Today.ToString("MMMM yyyy"); await Calculo.AnimateHeightAsync(200, 300, null); ExcelButton.IsEnabled = true; break; case "Anual": mes.Visibility = Visibility.Collapsed; año.Visibility = Visibility.Visible; calcular.Visibility = Visibility.Visible; await Calculo.AnimateHeightAsync(200, 300, null); range = DateTime.Today.ToString("yyyy"); ExcelButton.IsEnabled = true; break; } }