iPhone like red badge notification in a WPF project?

前端 未结 5 1979
时光说笑
时光说笑 2020-12-28 10:27

I have a C# WPF project which generates daily and weekly reports automatically. I want to inform the user when new reports are available, so I thought of a badge like on the

5条回答
  •  佛祖请我去吃肉
    2020-12-28 11:11

    I recently had the same requirement, and quickly knocked this UserControl together. It uses a short animation to draw the user's attention to the badge.

    Take a look at "Big Nick's" blog to see some elegant code for applying this UserControl to another UIElement as an Adorner (exactly what a 'badge' is!): http://blog.bignickolson.com/2009/10/15/overlaying-controls-in-wpf-with-adorners/

    (Thanks Nick!)

    alt text

    
        
            
    
        
    
        
            
                
        
    
    

提交回复
热议问题