Easy question: How to get the form width and height?
I don't mean thisform.width or thisform.height
These properties don't return the dimensions of the form as it was designed. They return the dimensions at runtime.
Example: I create a form 1400 pixels wide and compile the program to an EXE.
When the EXE runs on a computer with a smaller monitor, let's say 1280 wide, the form is truncated to fit on the smaller monitor and objects on the right site become invisible. thisform.width returns 1280.
But I want the original size so I can programmatically scale down to 90% or so, 1400*90%=1260 and not 1280*90%.
So I need the value of 1400 in this example. Is that possible with a general function?
I don't mean thisform.width or thisform.height
These properties don't return the dimensions of the form as it was designed. They return the dimensions at runtime.
Example: I create a form 1400 pixels wide and compile the program to an EXE.
When the EXE runs on a computer with a smaller monitor, let's say 1280 wide, the form is truncated to fit on the smaller monitor and objects on the right site become invisible. thisform.width returns 1280.
But I want the original size so I can programmatically scale down to 90% or so, 1400*90%=1260 and not 1280*90%.
So I need the value of 1400 in this example. Is that possible with a general function?