Table of Contents

Class StdLibEnumAttribute

Namespace
RDCore.SDK.Runtime.Abstract.StdLib
Assembly
RDCore.SDK.dll

Marks an enumeration as the internal representation of one of the standard library's predefined enums (MS-VBAL §6.1.1).

[AttributeUsage(AttributeTargets.Enum)]
public sealed class StdLibEnumAttribute : Attribute
Inheritance
StdLibEnumAttribute
Inherited Members

Remarks

A predefined enum is a global Enum: the type name binds in an As clause, and each of its constants resolves unqualified, which is what makes vbSunday a name on its own.

The marker is what makes the enum discoverable - every VBA project has the standard library whether or not anything references it (RD-VBAL §6.1), so nothing declares the set of enums a workspace gets, and the set is read off the SDK itself.

Constructors

StdLibEnumAttribute(string?)

Marks an enumeration as the internal representation of one of the standard library's predefined enums (MS-VBAL §6.1.1).

public StdLibEnumAttribute(string? name = null)

Parameters

name string

The enum's name in VBA source, when it differs from the conventional one.

Remarks

A predefined enum is a global Enum: the type name binds in an As clause, and each of its constants resolves unqualified, which is what makes vbSunday a name on its own.

The marker is what makes the enum discoverable - every VBA project has the standard library whether or not anything references it (RD-VBAL §6.1), so nothing declares the set of enums a workspace gets, and the set is read off the SDK itself.

Properties

Name

The enum's name in VBA source, or null for the conventional one: the declaring enumeration's name with its VB prefix cased down to Vb, so VBDayOfWeek is VbDayOfWeek.

public string? Name { get; }

Property Value

string

Remarks

FormShowConstants (§6.1.1.1) is the one predefined enum with no prefix at all, and states its name here.