scroll bar issue in MDI
-
I have an issue with my MDI application. When I drag my MDI child form outside the MDI Parent client area, scroll bars appear on the MDI parent form. How can i get rid of these scroll bars.(what we really want is, that scroll bars should never appear on the MDI Parent form), setting AutoScroll = false; HScroll = false; VScroll = false; does'nt work, scroll bars still appear. The default Windows behaviour for MDI applications is that they never have scroll bars on MDI Parent. thanks,
-
I have an issue with my MDI application. When I drag my MDI child form outside the MDI Parent client area, scroll bars appear on the MDI parent form. How can i get rid of these scroll bars.(what we really want is, that scroll bars should never appear on the MDI Parent form), setting AutoScroll = false; HScroll = false; VScroll = false; does'nt work, scroll bars still appear. The default Windows behaviour for MDI applications is that they never have scroll bars on MDI Parent. thanks,
sarah_malik wrote:
The default Windows behaviour for MDI applications is that they never have scroll bars on MDI Parent
Obviously, this is an incorrect assumption since you're not using a Win32 control. The MDI Child forms get rendered by a hidden, but in plain sight, control on the MDI Parent form. This is the MdiClient control. There is no property or method to turn off the scroll bars in the MdiClient control. What you were changing were the properties of the MdiParent form, not the MdiClient control. Every method I can think of for customizing the MdiClient control requires you to create your own version of the control, or process the window messages going to the control and alter them to keep the child windows from exceeding the boundries of the display area.
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007 -
sarah_malik wrote:
The default Windows behaviour for MDI applications is that they never have scroll bars on MDI Parent
Obviously, this is an incorrect assumption since you're not using a Win32 control. The MDI Child forms get rendered by a hidden, but in plain sight, control on the MDI Parent form. This is the MdiClient control. There is no property or method to turn off the scroll bars in the MdiClient control. What you were changing were the properties of the MdiParent form, not the MdiClient control. Every method I can think of for customizing the MdiClient control requires you to create your own version of the control, or process the window messages going to the control and alter them to keep the child windows from exceeding the boundries of the display area.
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007Thanks Dave :)