Can you use Java libraries in a VB.net program?

后端 未结 8 1934
青春惊慌失措
青春惊慌失措 2020-12-03 16:36

I\'m wondering if a Java library can be called from a VB.net application.

(A Google search turns up lots of shady answers, but nothing definitive)

相关标签:
8条回答
  • 2020-12-03 16:58

    If you can create COM components with Java, you can use tlbimp to create an interop assembly for using in VB.Net.

    If can create standard DLLs that can be used from C++ with Java, you can write P/Invoke declarations and call them from VB.Net.

    If you can create a web service with Java, you can generate proxy class from the WSDL and call it from VB.Net.

    In any case, chances are the Java component will live in a separate process. I doubt you can load both the Java VM and the CLR in the same process.

    0 讨论(0)
  • 2020-12-03 17:01

    If you have the source, Visual Studio will let you convert Java code into c#.

    0 讨论(0)
提交回复
热议问题