| 
UID746637积分137精华贡献 威望 活跃度 D豆 在线时间 小时注册时间2015-1-25最后登录1970-1-1 
 | 
 
| 
using System;
×
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?立即注册 
    using System.Collections.Generic;
 using System.ComponentModel;
 using System.Drawing;
 using System.Data;
 using System.Text;
 using System.Windows.Forms;
 using Autodesk.AutoCAD.Runtime;
 using Autodesk.AutoCAD.Windows;
 using Autodesk.AutoCAD.ApplicationServices;
 using AcadApp = Autodesk.AutoCAD.ApplicationServices.Application;
 
 namespace Hello
 {
 public partial class Menubar : UserControl
 {
 public Menubar()
 {
 InitializeComponent();
 
 }
 
 private void CommandTools_Load(object sender, EventArgs e)
 {
 //调整高度及大小
 this.Size = new System.Drawing.Size(200, 25);
 this.menuStrip1.Size = new System.Drawing.Size(60, this.Size.Height - 2);
 }
 }
 public class MenubarPalette
 {
 static PaletteSet ps;
 [CommandMethod("kaka")]
 
 public void ShowMenubar()//ShowMenubar
 {
 //如果面板还没有被创建
 if (ps == null)
 {
 //新建一个面板对象
 ps = new PaletteSet("");
 //添加菜单条面板项
 ps.Add("菜单条", new Menubar());
 }
 
 //在设置停靠属性之前,必须让面板可见,否则总是停靠在窗口的左侧
 ps.Visible = true;
 //必须在Dock前面
 ps.Size = new System.Drawing.Size(200, 27);//(15, 22);
 
 //设置面板停靠在窗口的顶面
 ps.Dock = DockSides.Top;
 }
 public void kaka()
 {
 ShowMenubar();
 }
 }
 }
 
 请问怎样去掉上下边缘,求指点
 
 
 
 | 
 
  |