Exemplo n.º 1
0
        void nbi_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e)
        {
            string objName = (sender as NavBarItem).Name.ToLower();

            switch (objName)
            {
            case "nbi_read":
                if (_ucReadList == null)
                {
                    _ucReadList = new ucReadList();
                }
                PlWorkAdd(_ucReadList);
                break;

            case "nbi_about":
                if (_ucAbout == null)
                {
                    _ucAbout = new ucAboutUs();
                }
                PlWorkAdd(_ucAbout);
                break;

            default:

                break;
            }
            this.Text = "网站管理 - " + (sender as NavBarItem).Caption;;
        }
Exemplo n.º 2
0
 /// <summary>
 /// 健康阅读
 /// </summary>
 //UcReadList _ucReadList = null;
 ///// <summary>
 ///// 关于我们
 ///// </summary>
 //UcAbout _ucAbout = null;
 public FrmWebSiteMgr()
 {
     InitializeComponent();
     foreach (NavBarItem nbi in navBarControl1.Items)
     {
         nbi.LinkClicked += new DevExpress.XtraNavBar.NavBarLinkEventHandler(nbi_LinkClicked);
     }
     Title       = "网站管理";
     _ucReadList = new ucReadList();
     PlWorkAdd(_ucReadList);
 }