How to Disable a Button after Clicking in Blazor

  Рет қаралды 1,729

Claudio Bernasconi

Claudio Bernasconi

Күн бұрын

Пікірлер: 8
@CRBarchager
@CRBarchager 9 ай бұрын
Thank you for the turotial. I've done something similar in the solution I've done since we had some very click-happy users.
@ClaudioBernasconi
@ClaudioBernasconi 9 ай бұрын
Excellent! Great to hear the solution worked for you.
@10Totti
@10Totti 9 ай бұрын
Nice tutorial!
@ClaudioBernasconi
@ClaudioBernasconi 9 ай бұрын
Thank you! 🙂
@stevendiazgomez6937
@stevendiazgomez6937 9 ай бұрын
Both disable and loading state UI is common implementation too
@MohammadKomaei
@MohammadKomaei 9 ай бұрын
How to disable the button in blazor ssr without any interactivity?
@ClaudioBernasconi
@ClaudioBernasconi 9 ай бұрын
Thanks for your question. At this time, there is no solution for disabling a button after click without interactivity that I am aware of. It doesn't matter if you use JavaScript or Blazor, you will end up having to change the state of your application and trigger a rerendering of parts of the website to achieve your goal. If anyone else knows a solution, please let us know. Also, what is holding you back from using Blazor Server interactivity or WebAssembly interactivity for your use case?
@badatcomputer
@badatcomputer 5 ай бұрын
I also found using a Try-Finally block is helpful. If(IsAddingToCart) then return, else place the IsAddingToCart=true before the Try, and in the Finally place IsAddingToCart=false. Solved my problems.
How to Share Blazor Components between Applications
3:53
Claudio Bernasconi
Рет қаралды 2,4 М.
What's NEW in Blazor in .NET 8?!
17:55
Claudio Bernasconi
Рет қаралды 4,5 М.
ЛУЧШИЙ ФОКУС + секрет! #shorts
00:12
Роман Magic
Рет қаралды 31 МЛН
The IMPOSSIBLE Puzzle..
00:55
Stokes Twins
Рет қаралды 116 МЛН
Человек паук уже не тот
00:32
Miracle
Рет қаралды 4 МЛН
СКОЛЬКО ПАЛЬЦЕВ ТУТ?
00:16
Masomka
Рет қаралды 1,8 МЛН
.NET 8 | What is Native AOT in .NET?
13:33
Claudio Bernasconi
Рет қаралды 10 М.
Blazor JavaScript Interop (Easy How To)
27:52
Coder Foundry
Рет қаралды 8 М.
Disable ASP NET button after click to prevent double clicking
13:13
Q&A: How Much Does A Channel With 1 Million Views Make?!
9:42
Claudio Bernasconi
Рет қаралды 438
DHH discusses SQLite (and Stoicism)
54:00
Aaron Francis
Рет қаралды 98 М.
Stop Using FirstOrDefault in .NET! | Code Cop #021
12:54
Nick Chapsas
Рет қаралды 92 М.
Blazor Localization in .NET 8 & Blazor Server
13:58
Claudio Bernasconi
Рет қаралды 9 М.
CSS Isolation in Blazor Applications in 10 Minutes or Less
9:49
IAmTimCorey
Рет қаралды 10 М.
9 UI Frameworks for .NET Desktop App Development [2024]
16:13
Claudio Bernasconi
Рет қаралды 37 М.
ЛУЧШИЙ ФОКУС + секрет! #shorts
00:12
Роман Magic
Рет қаралды 31 МЛН