Import Method (VBA Add-In Object Model)

Microsoft VBA

Import Method (VBA Add-In Object Model)

           

Adds a component to a project from a file; returns the newly added component.

Syntax

object.Import(filename) As VBComponent

The Import syntax has these parts:

Part Description
object Required. An object expression that evaluates to an object in the Applies To list.
filename Required. A String specifying path and file name of the component that you want to import the component from.

Remarks

You can use the Import method to add a component, form, module, class, and so on, to your project.