Disable user resize a form after specific size
I would like to let users resize my form but when they reach a specific size to disable this ability to make it smaller win开发者_如何学Pythondow than i want.
Any suggestions?
You can set the MinimumSize
property of the form to the minimum size you want to enforce.
There is also a mirror property MaximumSize
(mentioned for completeness).
Set the MinimumSize
property on your form. This will prevent the user from making the form any smaller than this value. Similarly, you can set the MaximumSize
property to ensure that they cannot make it any larger than that value.
Set the form's MinimumSize
property in the designer.
Set the form's MinimumSize property to the smallest size you want to allow.
精彩评论