MDI Question

trinkus79
09-07-2006, 02:23 PM
I started an MDI app, and I have a question that is hopefully easy to answer.

1. I don't like how the user can drag the child forms 'outside' of the mdi workspace. By this I mean the forms stay within the parent, but they can drag the child just slightly off the top of the parent workspace, or mostly off to the left of the workspace creating scroll bars that are pretty much useless. Can I limit it to where they can only drag it down and to the right?

any help or suggestions would help greatly

thanks in advance,
trinkus

CForrester
09-08-2006, 03:24 AM
You could try handling the event that's fired when a form moves, and check if it's gone out of bounds. And if it has, move it back in-bounds.

trinkus79
09-08-2006, 12:19 PM
You could try handling the event that's fired when a form moves, and check if it's gone out of bounds. And if it has, move it back in-bounds.

hmm, I guess that could work. Seems like more work than I really want to do...here's why... There can be up to 20 child forms open at once. I'd kinda like to get rid of the scroll bars completely on the parent form, but I'm not quite sure how to. I thought about it more last night, and I guess it doesn't matter if they drag the child forms off the workspace, I just don't want the scroll bars, because I inted to put a "view-> arrange" feature.

CForrester
09-08-2006, 12:21 PM
Well, if that's the case, check out my answer in this (http://www.xtremevbtalk.com/showthread.php?t=268829) thread. :) I believe that code should remove the MDI scrollbars.

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum