How to add a Custom Badge for an UIButton in cross platform mobile app development

I have an image button in top of the button I need to increase/decrease badge value so can any one help on this.

Thanks in Advance.....
Satish

Posts

  • GuillermoGutierrezGuillermoGutierrez ✭✭✭ ESMember ✭✭✭

    What have you tried?

  • SatishThotaSatishThota USMember

    Please suggest me how to implement I am new for Xamarin

  • GuillermoGutierrezGuillermoGutierrez ✭✭✭ ESMember ✭✭✭

    Well, I don't think that you can achieve a Cross-Platform implementation for that, because Buttons are interface elements, and interface elements are usually platform specific classes. On iOS I would create a custom class that has two subviews, one for the background button and another for the badge count view.

    The community will try to help you, but don't expect them to come with a full solution to a problem described in one line.

    See How to Ask guide on StackOverflow for a guide on how to write better questions that will provide you better answers.

  • SatishThotaSatishThota USMember

    GuillermoGutierrez plz find attached screen for my requirement how to show custom badge value for an control like UIButton through code behind

  • GuillermoGutierrezGuillermoGutierrez ✭✭✭ ESMember ✭✭✭

    There are many ready-to-use libraries that already implement what you are trying to do:

    Again, I think I've put more effort on finding a solution than you.

  • SatishThotaSatishThota USMember

    Thanks for your answer I need how to implement xamarin

  • BernieHabermeierBernieHabermeier ✭✭ USUniversity ✭✭

    @SatishThota -- I know it's like 2 years later, but I needed JSBadgeView as well, and instead of using the ObjectiveC library and linking to it natively, I saw the implementation was not all too long, so I just converted it to C#. It's here if you (or anyone is interested): https://github.com/habermeier/JSBadgeView

  • voidvoid ✭✭✭ DKBeta ✭✭✭

    I suppose the rather brilliant NGraphics could be used to whip up crossplatform badges in a jiffy. And perhaps be served up in the clever NControl framework.

    @ChristianFalch

Sign In or Register to comment.