VB6 - Making a new MSAPC.Apc crashes with 'Class does not support Automation or does not support expected interface'

1.3k views Asked by At

A VB6 application is being developed. Internally it uses VBA SDK version 7.1. The application is an Active X DLL. When the line of code 'Set Host = New MSAPC.Apc' is executed an exception is thrown. The exception reads "Class does not support Automation or does not support expected interface". Host is a class member defined like this "Public WithEvents Host As Apc". For all intents and purposes this code should work but does not and I can't find anything resolution.

1

There are 1 answers

0
user5102603 On

You need to select reference as "Microsoft APC 7.1 Object Library" and not "Microsoft APC 6.2 Object Library". This will solve the problem.

Regards, Anagha