Early Binding
The variable is declared to be of a specific object data type.
The process of an object being assigned to a variable is called binding and there are two types (early and late).
The object which a property or method belongs to is resolved at compile time.
Dim wdApp As Word.Application
Set wdApp = New Word.Application
This is much faster than late binding and is the preferred method.
The other advantage of early binding is that the Editor can display method and property Intellisense.
When you are using early bound then you must use the References dialog box to add a reference.
FSO Scripting Dictionary example
To assign a reference to a real instance of a class you must use the Set statement.
This creates an early bound reference to the object
Dim oMyObject As Object
Set oMyObject = Library.ClassName
© 2024 Better Solutions Limited. All Rights Reserved. © 2024 Better Solutions Limited TopPrevNext