为notifyIcon.icon属性赋图片

System.Drawing.Bitmap bp;
             bp = new Bitmap(Application.StartupPath + @"\image\" + MeiYeShuo.UI.BI.Frame.NotifyIcon);
             try
             {
                 notifyIcon1.Icon = Icon.FromHandle(bp.GetHicon());
                 notifyIcon1.Visible = true;
             }
             catch(Exception ex)
            {
                MessageBox.Show(ex.Message);
            }

 

posted @ 2013-09-29 17:47  美丽的矩阵  阅读(310)  评论(0编辑  收藏  举报