SALES: 1-800-867-1380
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

badge

Applies to Windows and Windows Phone

Specifies a badge's value or glyph.

Element hierarchy

<badge>

Syntax

<badge value    = "1-99" | "none" | "activity" | "alert" | "alarm" | "available" | ...
       version? = integer />

Key

?   optional (zero or one)

Attributes and Elements

Attributes

AttributeDescriptionData typeRequiredDefault value
value

Either a numeric value or a string value that specifies a predefined badge glyph. Numerically, this value can accept any valid integer. A value of 0 clears the badge, values from 1-99 display as given, and any value greater than 99 displays as 99+.

This attribute can be set to an integer or have one of the following values:

  • none
  • activity
  • alert
  • alarm
  • available
  • away
  • busy
  • newMessage
  • paused
  • playing
  • unavailable
  • error
  • attention
YesNone
version

The version of the badge XML schema this particular payload was developed for.

integerNo1

 

Child Elements

None.

Parent Elements

This outermost (document) element may not be contained by any other elements.

Remarks

This table shows the available status glyphs.

Windows glyphs

The available glyphs for use with Windows are shown here, together with their XML equivalent in the badge template.

StatusGlyphXML
noneNo badge shown<badge value="none"/>
activityThe activity badge; two circling arrows<badge value="activity"/>
alarmThe alarm badge<badge value="alarm"/>
alertThe alert badge<badge value="alert"/>
attentionThe attention badge; an exclamation point<badge value="attention"/>
availableThe available badge; a green dot<badge value="available"/>
awayThe away badge; a yellow dot<badge value="away"/>
busyThe busy badge; a red dot<badge value="busy"/>
errorThe error badge; an X<badge value="error"/>
newMessageThe new mail badge; an envelope<badge value="newMessage"/>
pausedThe paused badge<badge value="paused"/>
playingThe playing badge<badge value="playing"/>
unavailableThe unavailable badge; a gray dot<badge value="unavailable"/>

 

Windows Phone glyphs

As of Windows Phone 8.1, the available glyphs for use with Windows Phone are shown here, together with their XML equivalent in the badge template.

StatusGlyphXML
noneNo badge shown<badge value="none"/>
alertThe alert badge<badge value="alert"/>
attentionThe attention badge; an exclamation point<badge value="attention"/>

 

See also

Badge overview
App tiles and badges sample
How to send a glyph or numeric badge in a local notification
How to clear a badge
Guidelines and checklist for tiles and badges

Requirements

Namespace

http://schemas.microsoft.com/notifications/2012/badge.xsd

 

 

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2015 Microsoft