VB.NET EntryPointNotFoundException

VB.NET EntryPointNotFoundException

我有一个 x64 架构的 .DLL 文件,但没有足够的文档。我在 Visual Studio 2017 年尝试将以下内容作为 .NET Core 控制台应用程序添加 DLL 作为参考:

Imports System

Module Program
    Sub Main(args As String())
        Dim newObject As NewNamespace.NewInterface

        'Create New Instance
        newObject = NewNamespace.Factory.Instance.Create()

        'Do something

        'Clean up
        NewNamespace.Factory.Instance.Destroy()

    End Sub
End Module

当我尝试 运行 X64 调试中的代码时 CPU 我收到以下错误:

System.TypeInitializationException

EntryPointNotFoundException: A library name must be specified in a DllImport attribute applied to non-IJW methods.

编辑:删除了很多不必要的信息

在 VS2017 构建的 .Net Framework 控制台项目中使用相同的代码和引用,运行 代码没有错误。