Calling a function from within a DLL...

J

Jim Carlock

Using vbScript or JavaScript I'm guessing it's done with
objItem = CreateObject("objectName")

However I'm wondering... if there are any other methods in doing
the same? API calls within vbScript?
 
M

MD WebsUnlimited.com

Hi Jim,

If it is a "DLL" and a "COM" object then you would call it's methods
(functions) by instantiating it first (CreateObject) then using the objects
methods.

In JScript

var x = ActiveXCreate("Application.Object");

x.runMethod();
 
J

Jim Carlock

I've placed a DLL into a folder on a website. The DLL is an
ActiveXDLL I've downloaded from PSCODE.

The code on the page is currently:
<%@ Language="VBScript" %>
<head>
<title>Test Page</title>
</head>
<html>
<%
Dim x
Set x = CreateObject("ProperCaseName.clsName")
%>
</html>

The DLL has two public strings, FirstName and LastName.
It has one public subroutine, EnterName which presents
two InputBoxes which ask for the FirstName and LastName.

The file is located at:

http://www.microcosmotalk.com/test.asp
and the dll is located at the same location.

The source code for that file is found at:
http://www.pscode.com/vb/scripts/ShowCode.asp?txtCodeId=45194&lngWId=1

It's VB code that creates an ActiveX DLL. The DLL is
located at:
http://www.microcosmotalk.com/ProperCaseName.dll

I can see a couple problems:

1) The file is not registered on the webserver.
2) I don't know how to create/use an API call within .ASP.
3) I don't know how to register the file on the webserver. I guess
it's possible, but I don't have a clue. If I can't get the DLL to work
I'm going to have to figure out some other way to make something
to track the number of software items in use.

Thanks for your response, Mike. Thanks in advance to any more
replies that come through.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top