Forms

Form Styles

A form has four main styles that set how the form looks. These styles are:

0 - None
1 - Fixed Single
2 - Sizable
3 - Fixed Dialog
4 - Fixed Toolwindow
5 - Sizable Toolwindow

These styles are set in the BorderStyle property.

0 - None is a form with no border, no title bar at the top, and no minimize, close etc buttons. This style is usually used for Splash Screens. Default is no icon in the taskbar.

1 - Fixed Single is a form with a border, a title bar and a close button, with optional minimize and maximize. A form with its BorderStyle set to this cannot be resized, except using the minimize and maximize buttons. This defaults to not displaying a minimize and maximize button, but this can be changed by adjusting the MinButton and MaxButton properties.

2 - Sizable (Default) is a form with a border, a blue box and all the standard buttons. The dialog can be re-sized.

3 - Fixed Dialog is a form with a border, a blue box and a close button. No minimize and maximize buttons allowed. A form with its BorderStyle set to this cannot be resized. Default is no icon in the taskbar.

4 - A Fixed Toolwindow (a smaller X), and cannot be resized.

5 - A sizable Toolwindow (a smaller X), and can be resized.

You might also like...

Comments

About the author

James Crowley

James Crowley United Kingdom

James first started this website when learning Visual Basic back in 1999 whilst studying his GCSEs. The site grew steadily over the years while being run as a hobby - to a regular monthly audien...

Interested in writing for us? Find out more.

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Computer science education cannot make anybody an expert programmer any more than studying brushes and pigment can make somebody an expert painter” - Eric Raymond