Can't add a reference to the specified file

Not all object libraries or type libraries can be accessed by Visual Basic. This error has the following cause and solution:

  • You tried to use the Add References dialog box to add a reference to a type library or object library that can't be used by Visual Basic. Check the documentation for the object represented by the library to see if it's available in some other form that Visual Basic can use.

For additional information, select the item in question and press F1 (in Windows) or HELP (on the Macintosh).

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.