Call functions from VB Dll


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 4 of 4

Thread: Call functions from VB Dll

  1. #1
    Faisal Guest

    Call functions from VB Dll


    Hey All,

    Is there any way I can call the functions in a dll file created in VB in
    a java program.
    If there is, how can I do it. Do I have to do it in the same way as in VB,
    by declaring it first and calling the necessary fucntions.
    Thanks in advance.
    Faisal


  2. #2
    Paul Clapham Guest

    Re: Call functions from VB Dll

    Yes. You need to write a class that contains native methods that wrap the
    functions from the DLL. To do that you need to do some JNI programming. If
    you don't want to do that (I certainly didn't), then go to IBM Alphaworks
    (http://www.alphaworks.ibm.com/tech), select Java in the left frame, and
    look for Bridge2Java, a product which will generate the class for you.

    PC2

    "Faisal" <faisalm00@yahoo.com> wrote in message
    news:3ae51bc2$1@news.devx.com...
    >
    > Hey All,
    >
    > Is there any way I can call the functions in a dll file created in VB in
    > a java program.
    > If there is, how can I do it. Do I have to do it in the same way as in VB,
    > by declaring it first and calling the necessary fucntions.
    > Thanks in advance.
    > Faisal
    >




  3. #3
    Faisal Guest

    Re: Call functions from VB Dll


    Thanks Paul.
    I downloaded the program and did the set up.
    But I was not a able to generate the file.

    What should we enter in "Type Library Name". Isn't there where we should
    enter the name of our dll file. I entered the dll file there. But the error
    was " Unable to process the library type data".
    Please help.
    Faisal


    "Paul Clapham" <pclapham@core-mark.com> wrote:
    >Yes. You need to write a class that contains native methods that wrap the
    >functions from the DLL. To do that you need to do some JNI programming.

    If
    >you don't want to do that (I certainly didn't), then go to IBM Alphaworks
    >(http://www.alphaworks.ibm.com/tech), select Java in the left frame, and
    >look for Bridge2Java, a product which will generate the class for you.
    >
    >PC2
    >
    >"Faisal" <faisalm00@yahoo.com> wrote in message
    >news:3ae51bc2$1@news.devx.com...
    >>
    >> Hey All,
    >>
    >> Is there any way I can call the functions in a dll file created in VB

    in
    >> a java program.
    >> If there is, how can I do it. Do I have to do it in the same way as in

    VB,
    >> by declaring it first and calling the necessary fucntions.
    >> Thanks in advance.
    >> Faisal
    >>

    >
    >



  4. #4
    Paul Clapham Guest

    Re: Call functions from VB Dll

    And there's a place on the site you got that from where you can ask for help
    on it...

    PC2

    "Faisal" <faisalm00@yahoo.com> wrote in message
    news:3ae65f45$1@news.devx.com...
    >
    > Thanks Paul.
    > I downloaded the program and did the set up.
    > But I was not a able to generate the file.
    >
    > What should we enter in "Type Library Name". Isn't there where we should
    > enter the name of our dll file. I entered the dll file there. But the

    error
    > was " Unable to process the library type data".
    > Please help.
    > Faisal





Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center