By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,132 Members | 1,425 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,132 IT Pros & Developers. It's quick & easy.

Maximized form questions

P: n/a
For vb2005. At design time I set the main form's WindoState to Maximized
and I disabled the Maximize box. The user can Minimize the application
only.

When the program launches, the form is indeed Maximized. However:

1. The Maximized state of my form does not take the Windows taskbar state
into consideration. The form behaves as if the user has their taskbar set
to "autohide", even if they do not. The app extends all the way down to the
bottom of the screen, and on some machines the lower bounds of this area may
be obscured by the taskbar permanently set in the 'raised' position. Is
there a Maximize command that understands to account for the state of the
windows taskbar?

2. You can simply grab the title bar of my "Maximized" form and move it
around, as if it were a normal window that is not Maximized. Is there a way
to "lock" a Maximized window in place?

3. Double-clicking the title bar of my application performs a "restore
down", circumventing my disabled the maximize/restore button. Subsequently
double-clicking the application title bar does not "restore up" again, and
so the app is left stranded in a restore-down (shrunken) state that is a)
not desireable in the first place and b) irrecoverable unless the app is
restarted. Is there a way to disable the double-clicking of a title bar
from performing a restore down?
Mar 4 '06 #1
Share this Question
Share on Google+
1 Reply


P: n/a
1.) Screen.GetWorkingArea() get's the non taskbar working area, you could
dimension your form to this.
2.) Why don't you start it out as maximized, in the windowstate property.
If this doesn't work have you considered getting rid of the title bar? You
could always add your own minimize button and that would avoid the user
being able to move it. This is sort of an irritating behavior, but it is
your app.
This would solve item #3
3.) Otherwise, if you want to circumvent restore down, I think you
would probably need to do Sub classing, although I am curious, if you set
MaximumSize & MinimumSize properties based on the value in #1 above, maybe
it wouldn't allow this.

HTH,

Shane
"1388-2/HB" <1@1.net> wrote in message
news:Q6*******************@newssvr27.news.prodigy. net...
For vb2005. At design time I set the main form's WindoState to Maximized
and I disabled the Maximize box. The user can Minimize the application
only.

When the program launches, the form is indeed Maximized. However:

1. The Maximized state of my form does not take the Windows taskbar state
into consideration. The form behaves as if the user has their taskbar set
to "autohide", even if they do not. The app extends all the way down to
the bottom of the screen, and on some machines the lower bounds of this
area may be obscured by the taskbar permanently set in the 'raised'
position. Is there a Maximize command that understands to account for the
state of the windows taskbar?

2. You can simply grab the title bar of my "Maximized" form and move it
around, as if it were a normal window that is not Maximized. Is there a
way to "lock" a Maximized window in place?

3. Double-clicking the title bar of my application performs a "restore
down", circumventing my disabled the maximize/restore button.
Subsequently double-clicking the application title bar does not "restore
up" again, and so the app is left stranded in a restore-down (shrunken)
state that is a) not desireable in the first place and b) irrecoverable
unless the app is restarted. Is there a way to disable the
double-clicking of a title bar from performing a restore down?

Mar 4 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.