Results 1 to 2 of 2

Thread: Calling a method of a DLL

  1. #1

    Thread Starter
    Member
    Join Date
    Aug 2000
    Location
    Minneapolis
    Posts
    42
    Hi,
    I have a VB app on my machine.
    And i have a COM dll (DLL name is MTransfer.dll, class in the DLL is 'SetMT.cls',method in that class is 'DebitMT')residing on another MTS machine on the network (the computer name is 'MTS-Machine').
    Now i want to call the method(DebitMT) of that COM dll from the VB app on my machine.
    Can i know exactly what to do to call that DLL method(DebitMT) from my machine.
    And can i also know where the DLL actually runs, is it on my machine? or on the 'MTS-Machine'?

    Please let me know soon,
    Thanks,
    Srini

  2. #2
    Fanatic Member
    Join Date
    Jan 2001
    Location
    Vietnam
    Posts
    613
    To call the DLL file on the MTS machine you need to do:

    1. Export the package where the DLL file is located.
    2. Inside the package there is a folder, "CLIENT"
    3. Get the file *.EXE inside the client folder and run it on your local machine (this will register the DLL file so that your VP app can use)
    4. Start your project, add a reference of the DLL to your project. Once you've done this you can use:
    Code:
    Dim myvariable as MTransfer.SetMT
    Set myvariable = CreateObject("MTransfer.SetMT",servername)
    5. The DLL return will be run on which machine depends on the "Package Activation Type": Library or Server. If it is library, then it runs on your machine, if it is server then it runs on the server. You can find out about this be clicking on your package property, go to "Activation" tab.

    Hope this helps,
    TheBao

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width