asp.net - How to prevent repeated postbacks from confusing my business layer -


I have web application (ASP.NET 3.5) with a traditional 3 layer design. If user clicks on a button , Some middle and data-level code keeps running and the screen is refreshed. If the user clicks the button several times before the first completion of the postback, then my argument goes wrong and the app can end in an invalid state. What are the best ways to stop this?

I can use javascript to disable the button but it helps hide the problem. How can I create my business and data layers to manage it?

Three most popular methods (which are often used in tandem often):

< Ol>
  • Once clicked / pressed;
  • Use to avoid back button issues; And
  • so that you can not go back (but it should be used with caution and good reason).

  • Comments