Rect.Size

From Xojo Documentation

Property (As Size )
aRect.Size = newSizeValue
or
SizeValue = aRect.Size

New in 2019r2

Supported for all project types and targets.

The dimensions of the Rect.

Sample Code

This example is in the Paint event of a project. It computes the Size of the union of two rects.

// To demonstrate the Union feature, we'll draw a Cyan rectangle
// around both the draggable rects.
Var theSize As New Size
Var u As Rect = rectone.Union(recttwo)
buffer.Graphics.DrawingColor = CyanColor
buffer.Graphics.DrawRectangle(u.Left, u.Top, u.Width, u.Height)
theSize = u.Size