Articles in this section
Category / Section

How to change the shape of the BalloonTip in NotifyIcon?

1 min read

NotifyIcon shapes can be changed as Balloon, Rectangle, Rounded Rectangle Shapes by using the BalloonTipShapes Property.

The same has been explained in the following code example.

XAML

//Changes the shape of the Balloon Tip in Notify Icon
<Window x:Class="ColorPickerPallette.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:syncfusion ="http://schemas.syncfusion.com/wpf"
        Title="MainWindow" Height="350" Width="525">
<Grid>
    <Button x:Name="Button1" Content="Notify Show"   Click="Button1_Click" Width="100" Height="70"></Button>
<syncfusion:NotifyIcon x:Name="NotifyIcon" BalloonTipShape="RoundedRectangle" Background="AliceBlue" BalloonTipText="Custom NotifyIcon" BalloonTipIcon="Info"  ShowBalloonTipTime="500" HideBalloonTipTime="1000"></syncfusion:NotifyIcon>
</Grid>
</Window>

C#

//Changes the shape of the BallonTip in NotifyIcon
namespace NotifyIcon
{
  public partial class MainWindow : Window
    {
        public MainWindow()
        {
            InitializeComponent();
        }
    private void Button_Click(object sender, RoutedEventArgs e)
        {
            NotifyIcon.BalloonTipShape = BalloonTipShapes.Balloon;
            NotifyIcon.BalloonTipIcon = BalloonTipIcon.Info;
            NotifyIcon.BalloonTipText = "Custom Notify Icon";
            NotifyIcon.ShowBalloonTip(100);
        }
    }
}

Output

The following screenshots show the different shapes of the NotifyIcon.

Figure 1: Balloon Shape

C:\Users\ashok.murugesan\Desktop\KbTask\Rectangle.png

Figure 2: Rectangle Shape

C:\Users\ashok.murugesan\Desktop\KbTask\RoundedRectangle.png

Figure 3: Rounded Rectangle Shape

 

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please sign in to leave a comment
Access denied
Access denied