Active X DLL, calling from server

I have written a simple Active X Dll and would like to store it on a local server.

If the DLL is Stored on the Client,this code works:

DLL:

Function MakeBig(Value As String) As String
MakeBig = UCase(Value)
End Function

After making reference to DLL:

Dim Test As Project1.Class1
Private Sub Form_Load()
Dim bb As String
Set Test = New Project1.Class1
bb = Test.MakeBig("Reedy")
End Sub


I want to call it on the server and making a reference to the dll isn't what I need.

I have tried, but this doesn't work:

Declare Function makebig Lib "d:\Dll\Test.dll" (x As String) As String


bb = makebig("Reedy")


Error: Can't find dll entry point makebig in "C:\Dll\Test.Dll"


I want the dll on the server for when changes needed, it's easier to update!


LVL 1
Dean_ReedyAsked:
Who is Participating?
 
GordonpCommented:
IF your running an ActiveX component it needs to be an ActiveX Exe as it needs to run in its own process (since its on another machine).

When you compile the ActiveX Exe you need to set the project properties to create remote server files.
0
 
manojaminCommented:
I don't think you can call VB dll function as simple dll function. I think what you are looking for is DCOM.


0
 
manojaminCommented:
Read this, it will help you...

http://www.vb2themax.com/books/vbcom/dcom_2.asp

To understand all about DCOM read this,

http://www.vb2themax.com/books/vbcom/dcom_1.asp
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
corvanderlindenCommented:
I think you have to make a typelib for your client in
Project Properties|Component because you are using a remote dll

Then you reference this typelib
and set up Remote automation

Declaring a function is only for C/C++ like DLL's (these export their functions, VB ActiveX's do not)
0
 
caraf_gCommented:
To run it on a server it needs to be an activex exe methinks.
0
 
Dean_ReedyAuthor Commented:
Thanks again!
Time to learn DCOM!!!!
0
 
MoondancerCommented:
This question was awarded, but never cleared due to the JSP-500 errors of that time.  It was "stuck" against userID -1 versus the intended expert whom you awarded.  This corrects the problem and the expert will now receive these points; points verified.

Please click on your Member Profile and select "View Question History" to navigate through any open or locked questions you may have to update and finalize them.  If you are an EE Pro user, you can also choose Power Search to find all your open questions.

This is the Community Support link, if help is needed.  Also a question is posted there specific to these changes that apply to the experts here.  Also, I am including the link to our All Topics, since many new ones have recently been added.

http://www.experts-exchange.com/jsp/qList.jsp?ta=commspt
http://www.experts-exchange.com/jsp/zonesAll.jsp
 
Thank you,
Moondancer
Moderator @ Experts Exchange
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.