Struct VBRuntimeReference
The address of a variable, passed where the variable itself is: the argument of a ByRef parameter that names one.
public readonly record struct VBRuntimeReference : IRuntimeValue, IEquatable<VBRuntimeReference>
- Implements
- Inherited Members
Constructors
VBRuntimeReference(MemoryAddress, VBType?, VBArrayElementLocation?)
The address of a variable, passed where the variable itself is: the argument of a ByRef parameter that names one.
public VBRuntimeReference(MemoryAddress Value, VBType? DeclaredType = null, VBArrayElementLocation? Element = null)
Parameters
ValueMemoryAddressThe address of the variable.
DeclaredTypeVBTypeThe declared type of the variable, when the parameter it is passed to does not have it: a
Variantparameter given a variable of another type (MS-VBAL §5.3.1.11), which reads as aVariantbut is assigned as what the variable is declared to be. null when the parameter's own type is the variable's.ElementVBArrayElementLocationThe array and the subscripts of the element the variable is, when it is an element of an array passed to a native function: MS-VBA passes the address of the element where it is in the array's data, so the function sees the elements after it too. null for any other variable.
Fields
NullRef
public static readonly VBRuntimeReference NullRef
Field Value
Properties
BoxedValue
public object BoxedValue { get; }
Property Value
DeclaredType
The declared type of the variable, when the parameter it is passed to does not have it: a Variant parameter given a variable of another type
(MS-VBAL §5.3.1.11), which reads as a Variant but is assigned as what the variable is declared to be. null
when the parameter's own type is the variable's.
public VBType? DeclaredType { get; init; }
Property Value
Element
The array and the subscripts of the element the variable is, when it is an element of an array passed to a native function: MS-VBA passes the address of the element where it is in the array's data, so the function sees the elements after it too. null for any other variable.
public VBArrayElementLocation? Element { get; init; }
Property Value
Value
The address of the variable.
public MemoryAddress Value { get; init; }