mdi

LayoutMdi fails in form's OnLoad event

不羁的心 提交于 2019-11-28 06:44:14
问题 Hello I have OnLoad eventhandler like this: private void MainView_Load(object sender, EventArgs e) { LayoutMdi(MdiLayout.TileVertical); } But nothing happens. How do I make it work? 回答1: Yes, doesn't work. Probably because the child windows aren't visible yet. It works fine in the Shown event: protected override void OnShown(EventArgs e) { var f2 = new Form2(); f2.MdiParent = this; f2.Show(); f2 = new Form2(); f2.MdiParent = this; f2.Show(); this.LayoutMdi(MdiLayout.TileVertical); } 回答2:

How to hide a MDI Child form in Delphi?

社会主义新天地 提交于 2019-11-28 04:31:36
问题 How can I hide a MDIChild window in Delphi? I'm using this code in FormClose() event of my MDI children, but it doesn't seem to work: procedure TfrmInstrument.FormClose(Sender: TObject; var Action: TCloseAction); begin Action := caNone; ShowWindow(Handle, SW_HIDE); frmMainForm.MDIChildClosed(Handle); end; My child window is minimized instead of being hidden. 回答1: There is a protected procedure in TCustomForm defined as: procedure TCustomForm.VisibleChanging; begin if (FormStyle = fsMDIChild)

Assembly reference not found in XAML, but code compiles when referenced in xaml.cs class

*爱你&永不变心* 提交于 2019-11-27 14:44:55
问题 I've got a strange problem adding a dll reference. I've got a WPF application and am trying to use the WPF MDI library: http://wpfmdi.codeplex.com/ As stated in the instructions (which are very vague), I right-clicked on references in VS2012, clicked on Add reference.. , clicked on Browse.. and added my dll which I downloaded. Next, I added the following line in the XAML of my window: xmlns:mdi="clr-namespace:WPF.MDI;assembly=WPF.MDI" as stated in the instructions. However, when trying to add

windows 消息ID

家住魔仙堡 提交于 2019-11-27 13:47:12
1. WM_NULL=$0000: 2. WM_CREATE=$0001: 应用程序创建一个窗口 3. WM_DESTROY=$0002: 一个窗口被销毁 4. WM_MOVE=$0003: 移动一个窗口 5. WM_SIZE=$0005:改变一个窗口的大小 6. WM_ACTIVATE=$0006: 一个窗口被激活或失去激活状态; 7. WM_SETFOCUS=$0007: 获得焦点后 8. WM_KILLFOCUS=$0008: 失去焦点 9. WM_ENABLE=$000A: 改变enable状态 10. WM_SETREDRAW=$000B: 设置窗口是否能重画 11. WM_SETTEXT=$000C: 应用程序发送此消息来设置一个窗口的文本 12. WM_GETTEXT=$000D: 应用程序发送此消息来复13. 制对应窗口的文本到缓冲区 14. WM_GETTEXTLENGTH=$000E: 得到与一个窗口有关的文本的长度(不15. 包含空字符) 16. WM_PAINT=$000F: 要求一个窗口重画自己 17. WM_CLOSE=$0010: 当一个窗口或应用程序要关闭时发送一个信号 18. WM_QUERYENDSESSION=$0011: 当用户选择结束对话框或程序自己调用ExitWindows函数 19. WM_QUIT=$0012:

Controls in container form come over child form?

ぃ、小莉子 提交于 2019-11-27 09:09:58
In a container form I have menu and buttons to open ther forms. Here I am facing a problem when I open any form these buttns and lables come over newly opened form. Please guide me how I can manage this issue? I want to open a new form and keep these container form's controls in back ground of it. Anaya Upadhyay I've also got the same problem. I got an alternative solution as described below: Insert a timer control I've added the controls in a panel container And did the following private void timer1_Tick(object sender, EventArgs e) { if ((int)MdiChildren.GetLength(0) > 0) { panel1.Visible =

Visually remove/disable close button from title bar .NET

和自甴很熟 提交于 2019-11-27 06:48:11
问题 I have been asked to remove or disable the close button from our VB .NET 2005 MDI application. There are no native properties on a form that allow you to grey out the close button so the user cannot close it, and I do not remember seeing anything in the form class that will allow me to do this. Is there perhaps an API call or some magical property to set or function to call in .NET 2005 or later to do this? ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ More information: I need to maintain the minimize

Size/Location of Winforms MDI Client Area

╄→гoц情女王★ 提交于 2019-11-27 05:55:21
问题 Inside an MDI form is a client area that hosts the mdi child forms. How do I find out how big that area is? The best I can come up with so far is finding the total size of the parent's potential client area (mdiparent.ClientRectangle) and then subtracting off the sizes of components like toolbars, etc that take away from the client area. Is there a better way? 回答1: There is no property on a form that gives you access to the MDI client window. But you can find it back like this: public

FLEX- MDI窗口开发实例

☆樱花仙子☆ 提交于 2019-11-27 04:06:14
参考了杜增强的dpanel和Flex Doc Team的关于Creating Resizable and Draggable Flex Components 连接: dpanel Creating Resizable and Draggable Flex Components demo 下载 示例: 代码: application.mxml <? xml version="1.0" encoding="utf-8" ?> < mx:Application xmlns:mx ="http://www.adobe.com/2006/mxml" layout ="vertical" xmlns:mdi ="ext.containers.windows.mdi.*" width ="100%" height ="100%" creationComplete ="initCollections();" > < mx:Script > <![CDATA[ import mx.events.MenuEvent; import mx.collections.XMLListCollection; import mx.controls.Alert; import mx.managers.PopUpManager; import mx.managers.SystemManager; import mx

FLEX- MDI窗口开发实例(2)

元气小坏坏 提交于 2019-11-27 04:06:10
修改了一些bugs,下一步打算做个像ActiveDesktop的应用。 其他代码和 FLEX- MDI窗口开发实例 一样。 in MDITest1.mxml 1 <? xml version="1.0" encoding="utf-8" ?> 2 < ChildWindow xmlns ="ext.containers.windows.mdi.*" xmlns:mx ="http://www.adobe.com/2006/mxml" 3 width ="340" height ="214" xmlns:flexlib ="flexlib.containers.*" 4 title ="child window" layout ="absolute" 5 minButtonVisible ="{cbMin.selected}" 6 maxButtonVisible ="{cbMax.selected}" 7 closeButtonVisible ="{cbClose.selected}" 8 > 9 10 < mx:CheckBox id ="cbMin" x ="45" y ="49" label ="Min Button" selected ="true" /> 11 < mx:CheckBox id ="cbMax" x ="181" y ="49" label ="Max

Controls in container form come over child form?

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-27 04:01:03
问题 In a container form I have menu and buttons to open ther forms. Here I am facing a problem when I open any form these buttns and lables come over newly opened form. Please guide me how I can manage this issue? I want to open a new form and keep these container form's controls in back ground of it. 回答1: I've also got the same problem. I got an alternative solution as described below: Insert a timer control I've added the controls in a panel container And did the following private void timer1