Configuring BorderLayout in Windows Forms LayoutManagers
28 Apr 2021 / 1 minute to read
The configuration settings for the BorderLayout control have been given in this section.
The horizontal and vertical gaps between the child controls can be set using the following properties.
Gets or sets the horizontal spacing between the layout border and the components.
Gets or sets the vertical spacing between the layout border and the components.
this.borderLayout1.HGap = 10; this.borderLayout1.VGap = 10;
Me.borderLayout1.HGap = 10 Me.borderLayout1.VGap = 10
Configuring child controls
The child controls can be aligned to various positions (North, South, East, West, and Center) using the following property.
|Child control property||Description|
Position on borderLayout
Gets or sets the border position for a child components.
This property is added as an extended property in the properties window of the child control added to BorderLayout.