Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Dissallowing resize of a window form

Tags:

c#

.net

windows

I want that the user shouldn't be able to resize the window form. I was able to disable the maximize button but wasn't able to find any property to disable resizing.

Any help?

like image 653
Manish Avatar asked Apr 05 '10 14:04

Manish


People also ask

How do I resize a Windows Form?

By dragging either the right edge, bottom edge, or the corner, you can resize the form. The second way you can resize the form while the designer is open, is through the properties pane. Select the form, then find the Properties pane in Visual Studio. Scroll down to size and expand it.

How do I make Windows Forms not resizable?

First, select the form. Then, go to the properties menu. And change the property "FormBorderStyle" from sizable to Fixed3D or FixedSingle.

How do I fix form size in Visual Studio?

If you set the form's formborderstyle to fixeddialog, then the form is not sizeable. Yyou can also set the form startposition to make it center the entire screen or just center towards the application. Just click the form and inspect the properties of the form using the property inspector.

Is it possible to resize a control within the form design window?

To resize multiple controls on a form In Visual Studio, hold down the Ctrl or Shift key and select the controls you want to resize. The size of the first control you select is used for the other controls.


1 Answers

You need to set the FormBorderStyle property to one of the fixed values.

like image 163
Austin Salonen Avatar answered Oct 01 '22 12:10

Austin Salonen