Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Call Java Code From VB.net ?

Call Java Code From VB.net ?

Scheduled Pinned Locked Moved Visual Basic
csharpjavaquestion
5 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    ALQallaf
    wrote on last edited by
    #1

    Can i call java code from vb.net , is there any way to do it ?

    D Y 2 Replies Last reply
    0
    • A ALQallaf

      Can i call java code from vb.net , is there any way to do it ?

      D Offline
      D Offline
      Dave Kreskowiak
      wrote on last edited by
      #2

      Not directly. You have to use something in common that the two runtimes can use to communicate through. In this case, I believe that's COM. Depending on which codebase you want to use as a server, that code would have to expose some kind of COM interface (wrapper) so the other runtime can call it. In VB.NET, this is relatively easy. In Java, I have no idea what's involved, or if it's even possible. But, the client would just instantiate the server just like any other COM-based component. Dave Kreskowiak Microsoft MVP - Visual Basic

      C 1 Reply Last reply
      0
      • D Dave Kreskowiak

        Not directly. You have to use something in common that the two runtimes can use to communicate through. In this case, I believe that's COM. Depending on which codebase you want to use as a server, that code would have to expose some kind of COM interface (wrapper) so the other runtime can call it. In VB.NET, this is relatively easy. In Java, I have no idea what's involved, or if it's even possible. But, the client would just instantiate the server just like any other COM-based component. Dave Kreskowiak Microsoft MVP - Visual Basic

        C Offline
        C Offline
        Christian Graus
        wrote on last edited by
        #3

        I think Java does CORBA and not COM. Christian Graus - Microsoft MVP - C++

        1 Reply Last reply
        0
        • A ALQallaf

          Can i call java code from vb.net , is there any way to do it ?

          Y Offline
          Y Offline
          Yuvi Panda
          wrote on last edited by
          #4

          Well, You can either use J#. Or, use IKVM to call the Java Code. But, don't expect it to be fast, since you're running a VM on a VM.... Yuvi Panda T Microsoft Student Partner Blogs at : http://yuvipanda.blogspot.com

          A 1 Reply Last reply
          0
          • Y Yuvi Panda

            Well, You can either use J#. Or, use IKVM to call the Java Code. But, don't expect it to be fast, since you're running a VM on a VM.... Yuvi Panda T Microsoft Student Partner Blogs at : http://yuvipanda.blogspot.com

            A Offline
            A Offline
            ALQallaf
            wrote on last edited by
            #5

            i think i will try to use IKVM cause my code is not big so it will run with normal speed thanks all

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups