dashboard-devexpress-dot-dashboardcommon-dot-dashboardlayoutnode.md
Gets or sets the relative size of the layout item/group.
Namespace : DevExpress.DashboardCommon
Assembly : DevExpress.Dashboard.v25.2.Core.dll
NuGet Package : DevExpress.Dashboard.Core
[DefaultValue(1)]
public double Weight { get; set; }
<DefaultValue(1)>
Public Property Weight As Double
| Type | Default | Description |
|---|---|---|
| Double | 1 |
A Double value that specifies the relative size of the layout item/group.
|
The Weight property specifies the size of the layout item/group relative to the total weight of the parent’s layout items/groups.
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Weight property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
winforms-dashboard-window-calculation-example/CS/WindowCalculationExample/TabPageLoadHelper.cs#L80
{
copyTo.Weight = copyFrom.Weight;
if ((copyTo is DashboardLayoutGroup) && (copyFrom is DashboardLayoutGroup))
winforms-dashboard-window-calculation-example/VB/WindowCalculationExample/TabPageLoadHelper.vb#L97
Private Sub LayoutCopy(ByVal copyFrom As DashboardLayoutNode, ByVal copyTo As DashboardLayoutNode)
copyTo.Weight = copyFrom.Weight
If(TypeOf copyTo Is DashboardLayoutGroup) AndAlso (TypeOf copyFrom Is DashboardLayoutGroup) Then CType(copyTo, DashboardLayoutGroup).Orientation = CType(copyFrom, DashboardLayoutGroup).Orientation
See Also