Reload the Page (windows) during Button Click, Spinner stops working in WPF C #

1

I'm doing a WPF application in C #, which when I click the browse button in the database. It starts spinning a "Spinner" that is inside the UserControl;

 private void BtnBusca_Click(object sender, RoutedEventArgs e)
 {
    MessageControl.Visibility = Visibility.Visible;
    Dispatcher.Invoke(new Action(() => { }), DispatcherPriority.ContextIdle, null);
    FuncaoBuscabanco(TbCampoBusca.Text);
    MessageControl.Visibility = Visibility.Collapsed;
}

When you click the button, it does not stop scrolling and continues to search the database.

    
asked by anonymous 05.07.2018 / 21:12

0 answers