18 Jun

C# Notify Icon Example

A notification icon notifies the user. In Windows there is a Notification Icons section, typically in the bottom right corner. To create a notify icon application, we use NotifyIcon instance in System.Windows.Forms namespace.

Example Code:

            NotifyIcon trayIcon = new NotifyIcon();    
            trayIcon.Icon = new Icon(@"C:\csharp.ico");
            trayIcon.Text = "New message";
            trayIcon.Visible = true;
            trayIcon.ShowBalloonTip(2000, "Information", "A new message received!", ToolTipIcon.Info);
screenshot of notify icon

screenshot of notify icon