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 8160757
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T18:20:56+00:00 2026-06-06T18:20:56+00:00

In my Windows Phone Application when I press a button for navigating to Page1

  • 0

In my Windows Phone Application when I press a button for navigating to Page1 and before it finishes loading it, I press button to navigate to Page2, my application crashes. Is it correct and what is the best practice to implement this behaviour?

Update
Generally I think, the best way for me will be to block all buttons on the screen after one of them was pressed and make them active after navigation finish, so how can I do this?

  • 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-06T18:20:58+00:00Added an answer on June 6, 2026 at 6:20 pm

    The best practice is this case is to disable the Click event after the first click.
    If your button was named b and you either assigned event handler in xaml or in codebehind
    like

    b.Click += new RoutedEventHandler(ButtonOnClick);
    
    void ButtonOnClick(object sender, RoutedEventArgs e)
    {
        b.Click -= new RoutedEventHandler(ButtonOnClick);
    
        // Navigate away now.
    }
    

    Actually my sample will stop double click on current button only but you can disable other buttons as well.

    in one of my apps, i maintain a List which i iterate and show / hide, enable / disable a required. all you do is iterate and set the correct property.

    foreach(var button in myButtons)
        button.IsEnabled = false;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

net to make a Windows Phone application. I have a listBox on page1 called
I am creating a windows phone application, which need to store some data in
In my Windows Phone application I need to accept an untrusted certificate by default
I am developing a windows phone application. The webclient does not fire as I
I have a windows phone application and I need to add a user control
I'm building a Windows Phone application and my client has given me a list
I am developing a Windows Phone Application and from this application I am accessing
I'm busy working on a windows phone application that calls a servlet that then
I am having a problem with my Windows Phone application. When I get the
i am trying to use the Google APIS in developing a Windows Phone application,

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.