1.

Solve : c#sharpdevelop window size?

Answer»

How would I go about checking the mainform window size? I am wanting to write an if then state that more or LESS SAYS that

Code: [Select]if (window size == (360, 105)){
do whatever
}

or

Code: [Select]if (window size == minimum size){ // (360, 105) is the minimum size for the window
do whatever
}
FORMS have a width and height property which you can check after the fact:

Code: [Select]if form.width &LT; 360 Or form.height < 105 {
do errorcondition
}

You could also do this in the onResize event for the form and notify the user immediately if the form goes below the minimum size.

I'm learning C# just RESEARCHING your questions.

Good luck.cool, thanks.



Discussion

No Comment Found