3

help me how to add a counter badge to application icon. I am in really need of this. I searched and analyses only one way to install widget but could not find widget for application icon for badges.

Add a Counter Badge

Like this

Community
  • 1
  • 1
LuminiousAndroid
  • 1,557
  • 4
  • 18
  • 28
  • 1
    See http://stackoverflow.com/questions/5569695/android-is-it-possible-to-update-a-imageview-imagebutton-with-a-number-to-show – ccheneson Jun 11 '12 at 07:26
  • Hey ccheneson Thank you for this. Do you have any test project for application widgets ? – LuminiousAndroid Jun 11 '12 at 07:31
  • No, but all the required code is in the link above. There is also an Actvity test to test the count as nornally you can only update a widget once every 30 min. – ccheneson Jun 11 '12 at 07:36
  • Okay, Thanks a lot for your precious Help !! – LuminiousAndroid Jun 11 '12 at 07:39
  • Hey ccheneson Mostly i got it but one thing is it compulsary to add AppWidgetProviderInfo and AppWidgetProvider class to my code. and where your test activity exist ...Is it main activity ? – LuminiousAndroid Jun 11 '12 at 07:53
  • The test activity is there just to check that the value of the badge is updated. If you want to create an Widget, then Yes, AppWidgetProvider is compulsary (dunno about AppWidgetProviderInfo, long time I havent worked with Android) . I ll see at home if I still have the code to test the widget itself – ccheneson Jun 11 '12 at 08:00

0 Answers0