private Assembly CreateActiveXWrapper(string ocxFileName)
        {
            bool hasOutputDirectory = !string.IsNullOrEmpty(OutputDirectory);

            if (hasOutputDirectory && !Directory.Exists(OutputDirectory))
            {
                Directory.CreateDirectory(OutputDirectory);
            }

            if (_options == null)
            {
                _options = new AxImporter.Options();
                _options.outputDirectory = OutputDirectory;
                _options.keyPair = KeyPair;
                _options.references = new AxImporterResolver(ImportedFileNames);
            }
            else
            {
                _options.outputName = null;
            }

            AxImporter importer = new AxImporter(_options);
            importer.GenerateFromFile(new FileInfo(ocxFileName));

            foreach (string fileName in importer.GeneratedAssemblies)
            {
                _existingWrappers.Add(Path.GetFileNameWithoutExtension(fileName), fileName);
                Assembly libraryAssembly = Assembly.LoadFrom(fileName);
                ImportedFileNames[libraryAssembly.FullName] = Path.GetFileName(fileName);
            }

            return Assembly.LoadFrom(hasOutputDirectory
                                         ? Path.Combine(OutputDirectory, _options.outputName)
                                         : _options.outputName);
        }