Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8789751
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T22:30:02+00:00 2026-06-13T22:30:02+00:00

I have wpf applicaton based on MVVM pattern. I have annoying issue and I

  • 0

I have wpf applicaton based on MVVM pattern.
I have annoying issue and I can`t figure how can I solve it.

My application is wizard application, When the user press “Next” I am starting some progress in another thread (backgroundworker), when the bgWorker is starting he set CanMoveNext = false which binded to Next button isEnabled property and when the bgworker is finish he set back CanMoveNext = true;

When CanMoveNext get IsEnabled = false the UI show it immediately but after the isEnabled propery set back to true the UI do the refresh just after a mouse click or keyboard key press.

After Im changing the property Im using OnPropertyChanged() method, I even tried use CommandManager.InvalidateRequerySuggested(); but it`s still not get refreshed without mouseclick.

How can I solve this problem?

Here is my code:

       public override bool CanMoveNext
        {
            get
            {
                return canMoveNext;
            }
            set
            {
                canMoveNext = value;
                OnPropertyChanged("CanMoveNext");
            }
        }



    public void StartProgress()
            {

                CanMoveNext = false;
                InitBGworkers(out bgStartPersonalWorker);
    bgStartPersonalWorker.RunWorkerAsync();
    }



        void bgStartPersonalWorker_DoWork(object sender, DoWorkEventArgs e)
        {
            DoStuff();
        }



        void bgStartPersonalWorker_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
                {
     CanMoveNext = true;
//Even  CommandManager.InvalidateRequerySuggested(); doen`t help
                }

//Code from XAML

<Button Content="{Binding ButtonNextCaption}" IsEnabled="{Binding CanMoveNext, UpdateSourceTrigger=PropertyChanged}" Command="{Binding Path=NavigateNextCommand}" Margin="5,0,5,0" Width="100" Height="40" FontSize="14" FontWeight="Bold"/>

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T22:30:03+00:00Added an answer on June 13, 2026 at 10:30 pm

    I figure how solve it:

                Application.Current.Dispatcher.BeginInvoke(new ThreadStart(() =>
                {
                    CommandManager.InvalidateRequerySuggested();
    
                }));
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a WPF application based on PRISM that utilizes the MVVM pattern. I
I'm writing a WPF application using the MVVM pattern, based on the following article:
I have a small WPF application based on MVVM priniciples. So far I had
In my MVVM based WPF application I have a lot of different ViewModel types
I have an MVVM-based WPF application that relies on Caliburn.Micro . In one view,
I am creating a page-based WPF application using MVVM. I have created a custom
I designed a WPF application based on MVVM pattern and I need to get
I have a WPF app based on MVVM pattern with Prism. We have a
I have a VS11 beta WPF application with a Microsoft Datagrid based on a
I have WPF Application where I have One main form and other user controls

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.