ToolbarItem.BadgeText Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets or sets the badge text displayed on this toolbar item.
Set to a non-empty string to show a text/count badge, an empty string to show a dot indicator, or null to hide the badge.
This is a bindable property.
public:
property System::String ^ BadgeText { System::String ^ get(); void set(System::String ^ value); };
public string BadgeText { get; set; }
member this.BadgeText : string with get, set
Public Property BadgeText As String
Property Value
Remarks
Badge rendering varies by platform:
- Android: Uses Material Design
BadgeDrawableviaBadgeUtils. Supports numeric and text badges on primary toolbar items. Empty string shows a small dot indicator. - iOS/MacCatalyst: Uses the native
UIBarButtonItem.badgeAPI introduced in iOS 26. On earlier iOS versions, the badge is silently ignored. Empty string shows a dot indicator. - Windows: Uses WinUI
InfoBadgeoverlaid on the toolbar button. Numeric values display as counts; non-numeric text and empty string display as a dot indicator.
Badges are only displayed on primary toolbar items (items with Order set to Primary or Default). Secondary (overflow) items do not display badges.