Exemplo n.º 1
0
        private void ConfigContextMenu(Object sender, StatusEventArgs e)
        {
            MyMenu    menu      = new MyMenu(_dgvMain);
            MenuStrip menuStrip = menu.CreateMainMenu();

            this.Controls.Remove(this.MainMenuStrip);
            this.MainMenuStrip = menuStrip;
            this.Controls.Add(menuStrip);

            _dgvCar.ContextMenuStrip = menu.CreateContextMenu();
        }
Exemplo n.º 2
0
        private void ConfigContextMenu(Object sender, StatusEventArgs e)
        {
            MyMenu menu = new MyMenu(_dgvMain);
            MenuStrip menuStrip = menu.CreateMainMenu();

            this.Controls.Remove(this.MainMenuStrip);
            this.MainMenuStrip = menuStrip;
            this.Controls.Add(menuStrip);

            _dgvCar.ContextMenuStrip = menu.CreateContextMenu();
        }