Board index » delphi » Form's WindowState wsMaximized question

Form's WindowState wsMaximized question

Delphi 3.02 question.

If I set a Form's WindowState property to wsMaximized in either design time or in code,
it doesn't fully maximize on my screen, and is offset down and to the right of the
desktop size.  What could I be doing wrong?  (I'm not sure what other details to provide
-- I think its a plain vanilla form...)

Thanks, Brian

 

Re:Form's WindowState wsMaximized question


Have you tried simply calling ShowWindow(Handle, sw_Maximized) on your form?
--Joe

Quote
Brian Feifarek <feifa...@jps.net> wrote in message

news:36C623CB.3E3@jps.net...
Quote
>Delphi 3.02 question.

>If I set a Form's WindowState property to wsMaximized in either design time
or in code,
>it doesn't fully maximize on my screen, and is offset down and to the right
of the
>desktop size.  What could I be doing wrong?  (I'm not sure what other
details to provide
>-- I think its a plain vanilla form...)

>Thanks, Brian

Re:Form's WindowState wsMaximized question


Quote
> If I set a Form's WindowState property to wsMaximized in either design time or in code,
> it doesn't fully maximize on my screen, and is offset down and to the right of the
> desktop size.  What could I be doing wrong?

Brian,

you have the Position property of the form set to poScreenCenter. That does conflict with
WindowState wsMaximized, use poDefault instead.

Peter Below (TeamB)  100113.1...@compuserve.com)
No e-mail responses, please, unless explicitely requested!

Re:Form's WindowState wsMaximized question


Nope, I hadn't tried that, but I will in a minute.  

Thanks!  (And by the way, Peter was right, I had Position = poScreenCenter, which
apparently interferes with Maximized)

Brian

Quote
Joe Ackbar wrote:

> Have you tried simply calling ShowWindow(Handle, sw_Maximized) on your form?

Re:Form's WindowState wsMaximized question


Yep, Peter, you're absolutely right.  I'll switch the Position property and give it a
try.

Thanks, Brian

Quote
Peter Below (TeamB) wrote:

> > If I set a Form's WindowState property to wsMaximized in either design time or in code,
> > it doesn't fully maximize on my screen, and is offset down and to the right of the
> > desktop size.  What could I be doing wrong?

> Brian,

> you have the Position property of the form set to poScreenCenter. That does conflict with
> WindowState wsMaximized, use poDefault instead.

> Peter Below (TeamB)  100113.1...@compuserve.com)
> No e-mail responses, please, unless explicitely requested!

Re:Form's WindowState wsMaximized question


Yep, Peter, you're absolutely right.  I'll switch the Position property and give it a
try.

Thanks, Brian

Quote
Peter Below (TeamB) wrote:

> > If I set a Form's WindowState property to wsMaximized in either design time or in code,
> > it doesn't fully maximize on my screen, and is offset down and to the right of the
> > desktop size.  What could I be doing wrong?

> Brian,

> you have the Position property of the form set to poScreenCenter. That does conflict with
> WindowState wsMaximized, use poDefault instead.

> Peter Below (TeamB)  100113.1...@compuserve.com)
> No e-mail responses, please, unless explicitely requested!

Other Threads