.NET MAUI ProgressBar Events
The ProgressBar for .NET MAUI exposes the following events:
-
ProgressChanged
event is raised when progress is changed. TheProgressChanged
event handler receives two parameters:- A
ProgressChangedEventArgs
which has aProgress
(double
) property. Using this property you can get the current progress of the ProgressBar control.
- A
ProgressCompleted
event is raised when the Value of the ProgressBar reaches theMaximum
value.
Example with ProgressChanged
and ProgressCompleted
events
A simple RadLinearProgressBar
definition:
Add the following namespace:
ProgressChanged
event in code behind. The Label text is updated with the current Progress
value:
ProgressCompleted
event in code behind. The Label text is updated with Text = "Completed"
when the progress reaches the Maximum
value:
The final result when using the ProgressChanged
and ProgressCompleted
events on Android:
And on WinUI:
For the ProgressBar Events example refer to the SDKBrowser Demo Application.