开发工具:
文件大小: 83kb
下载次数: 0
上传时间: 2018-01-29
详细说明: namespace OutLookBarDemo { public partial class FrmMain : Form { public FrmMain() { InitializeComponent(); #region 初始化 OutLookBar outlookBar.BorderStyle = BorderStyle.FixedSingle; outlookBar.Initialize(); IconPanel iconPanel1 = new IconPanel(); IconPanel iconPanel2 = new IconPanel(); IconPanel iconPanel3 = new IconPanel(); outlookBar.AddBand("工具条A", iconPanel1); outlookBar.AddBand(" 工具条B", iconPanel2); outlookBar.AddBand("工具条C", iconPanel3); //0 iconPanel1.AddIcon("信息查询", Image.FromFile(@"Image\1.ico"), new EventHandler(PanelEventA)); //1 iconPanel1.AddIcon("购物车管理", Image.FromFile(@"Image\2.ico"), new EventHandler(PanelEventA)); iconPanel1.AddIcon("信息查询", Image.FromFile(@"Image\1.ico"), new EventHandler(PanelEventA)); //1 iconPanel1.AddIcon("购物车管理", Image.FromFile(@"Image\2.ico"), new EventHandler(PanelEventA)); iconPanel1.AddIcon("信息查询", Image.FromFile(@"Image\1.ico"), new EventHandler(PanelEventA)); //1 iconPanel1.AddIcon("购物车管理", Image.FromFile(@"Image\2.ico"), new EventHandler(PanelEventA)); iconPanel1.AddIcon("信息查询", Image.FromFile(@"Image\1.ico"), new EventHandler(PanelEventA)); //1 iconPanel1.AddIcon("购物车管理", Image.FromFile(@"Image\2.ico"), new EventHandler(PanelEventA)); iconPanel1.AddIcon("信息查询", Image.FromFile(@"Image\1.ico"), new EventHandler(PanelEventA)); //1 iconPanel1.AddIcon("购物车管理", Image.FromFile(@"Image\2.ico"), new EventHandler(PanelEventA)); iconPanel1.AddIcon("信息查询", Image.FromFile(@"Image\1.ico"), new EventHandler(PanelEventA)); //1 iconPanel1.AddIcon("购物车管理", Image.FromFile(@"Image\2.ico"), new EventHandler(PanelEventA)); //2 iconPanel2.AddIcon("电子邮件", Image.FromFile(@"Image\3.ico"), new EventHandler(PanelEventB)); //3 iconPanel2.AddIcon("密码管理", Image.FromFile(@"Image\4.ico"), new EventHandler(PanelEventB)); //4 iconPanel3.AddIcon("时间设置", Image.FromFile(@"Image\4.ico"), new EventHandler(PanelEventC)); outlookBar.SelectBand(0); #endregion } public void PanelEventA(object sender, EventArgs e) { Control ctrl = (Control)sender; PanelIcon panelIcon = ctrl.Tag as PanelIcon; string clickInfo = string.Empty; switch (panelIcon.Index) { case 0: clickInfo = "信息查询"; break; case 1: clickInfo = "购物车管理"; break; } this.label1.Text = string.Format("您选择了 {0}", clickInfo); } public void PanelEventB(object sender, EventArgs e) { Control ctrl = (Control)sender; PanelIcon panelIcon = ctrl.Tag as PanelIcon; string clickInfo = string.Empty; switch (panelIcon.Index) { case 0: clickInfo = "电子邮件"; break; case 1: clickInfo = "密码管理"; break; } this.label1.Text = string.Format("您选择了 {0}", clickInfo); } public void PanelEventC(object sender, EventArgs e) { Control ctrl = (Control)sender; PanelIcon panelIcon = ctrl.Tag as PanelIcon; string clickInfo = string.Empty; switch (panelIcon.Index) { case 0: clickInfo = "时间设置"; break; } this.label1.Text = string.Format("您选择了 {0}", clickInfo); } } } ...展开收缩
(系统自动生成,下载前可以参看下载内容)
下载文件列表
相关说明
- 本站资源为会员上传分享交流与学习,如有侵犯您的权益,请联系我们删除.
- 本站是交换下载平台,提供交流渠道,下载内容来自于网络,除下载问题外,其它问题请自行百度。
- 本站已设置防盗链,请勿用迅雷、QQ旋风等多线程下载软件下载资源,下载后用WinRAR最新版进行解压.
- 如果您发现内容无法下载,请稍后再次尝试;或者到消费记录里找到下载记录反馈给我们.
- 下载后发现下载的内容跟说明不相乎,请到消费记录里找到下载记录反馈给我们,经确认后退回积分.
- 如下载前有疑问,可以通过点击"提供者"的名字,查看对方的联系方式,联系对方咨询.