what's the deal with me.width and me.height?

  • Thread starter Thread starter Richy
  • Start date Start date
R

Richy

Hi,

I am running at a resolution of 1280 x 1024, but my maximised form
returns a Me.Width of 1440 whereas
System.Windows.Forms.SystemInformation.WorkingArea.Width returns 1280,
which is the correct value, as there is nothing docked to the desktop
on either the left or the right sides. The
System.Windows.Forms.SystemInformation.WorkingArea.Height returns 962,
as I have a toolbar docked at the top, and there is the taskbar at the
bottom. However, Me.Height returns 967 which is more than the working
area height.

Can somebody explain these discrepancies and how can I obtain the
correct figures?

Thanks,

Richy
 
Richy,

If there is whatever in your form does not decrease the hight of your form.

me. is the class you are working in, normally this is in this kind of
questions the form.

Cor
 
The class referred to by "Me." is indeed a standard Windows form. The
form is set in the designer to be maximized, I do not control the
height myself, it is set by the system. I have also noticed that on
alternate runs, the given height can vary by 3 pixels - despite it
being maximized and supposedly taking up the available screen space
(which is not changing from run to run).

It's certainly weird behaviour.

Thanks,

Richy
 
Back
Top