Class ObjectCreationFact
The class of the object a CreateObject call creates, when the programmatic identifier it is given is written as a constant: what the object is known to
be, beyond the Object its declared type says.
public sealed record ObjectCreationFact : IEquatable<ObjectCreationFact>
- Inheritance
-
ObjectCreationFact
- Implements
- Inherited Members
Remarks
A fact for tooling - what a completion list offers after the object, what an analyzer says of the call - and for nothing else. It is never a declaration: the object is late-bound, its members are found when they are called (MS-VBAL §6.1.2.8.1.4), and nothing that is or is not true of the class described here is a compile error or changes what the program does.
A class is found by the identifier its library describes it with (Runtime.Libraries.ClassDescription.ProgId), in the library the identifier's
first part names, without regard to case. An identifier that names no version (DAO.DBEngine) is the class whose identifier is the same with one
(DAO.DBEngine.120): which version a machine has is its own to say, and the class is the same one. 🚧 TODO A library whose name is not the first part
of the identifiers of its classes (VBScript_RegExp_55, for VBScript.RegExp) is not found.
Constructors
ObjectCreationFact(string, string, string, ObjectClassSource)
The class of the object a CreateObject call creates, when the programmatic identifier it is given is written as a constant: what the object is known to
be, beyond the Object its declared type says.
public ObjectCreationFact(string ProgId, string Library, string ClassName, ObjectClassSource Source)
Parameters
ProgIdstringThe programmatic identifier, as it is written.
LibrarystringThe name of the library the class is of.
ClassNamestringThe name of the class.
SourceObjectClassSourceWhere it was found.
Remarks
A fact for tooling - what a completion list offers after the object, what an analyzer says of the call - and for nothing else. It is never a declaration: the object is late-bound, its members are found when they are called (MS-VBAL §6.1.2.8.1.4), and nothing that is or is not true of the class described here is a compile error or changes what the program does.
A class is found by the identifier its library describes it with (Runtime.Libraries.ClassDescription.ProgId), in the library the identifier's
first part names, without regard to case. An identifier that names no version (DAO.DBEngine) is the class whose identifier is the same with one
(DAO.DBEngine.120): which version a machine has is its own to say, and the class is the same one. 🚧 TODO A library whose name is not the first part
of the identifiers of its classes (VBScript_RegExp_55, for VBScript.RegExp) is not found.
Properties
ClassName
The name of the class.
public string ClassName { get; init; }
Property Value
Library
The name of the library the class is of.
public string Library { get; init; }
Property Value
ProgId
The programmatic identifier, as it is written.
public string ProgId { get; init; }
Property Value
Source
Where it was found.
public ObjectClassSource Source { get; init; }