示例#1
0
 internal static void ShowWindow(BM.AddIn addIn)
 {
     if (null != currentControl)
     {
         currentControl.Focus();
         return;
     }
     currentControl = new BM.WPF.DockableWindow();
     currentControl.Attach(addIn, "Control", new System.Drawing.Size(100, 200));
     currentControl.Content = new wpfUC(addIn);
     currentControl.Title   = "Test";
     //必须先连接上在设置
     currentControl.WindowContent.CanDockVertically = false;
     currentControl.Show();
 }
示例#2
0
        internal static void ShowWindow(BM.AddIn addIn)
        {
            if (null != currentControl)
            {
                currentControl.Focus();
                return;
            }

            currentControl = new BM.WPF.DockableWindow();
            //在Attach之前修改窗体属性
            currentControl.Title = "按图层输出工程量";
            currentControl.Attach(addIn, "wpfControl", new System.Drawing.Size(150, 250));
            currentControl.Content = new GetQuantitiesUC(addIn);
            //currentControl.Icon = BitmapFrame.Create(new Uri(@"C:\Program Files\Bentley\MicroStation CONNECT Edition\MicroStation\Mdlapps\Image\pdiwt_icon.ico", UriKind.Absolute));
            //不能停靠
            currentControl.WindowContent.CanDockHorizontally = false;
            currentControl.WindowContent.CanDockVertically   = false;
            currentControl.WindowContent.CanDockInCenter     = false;
            currentControl.Show();
        }