Calling a VB DLL from ASP

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



I asked this question in the ASP forum, but they only helped to a point.
aso here i am asking it on the vb forum

my problem is this:

I have written a VB wrapper DLL that calls a C++ DLL. I then call tgis VB
DLL from an asp page, pass it two strings, then get back an encrypted string
out of the two I pass it. The issue is that when I am on the VB IDE and I
run the DLL then call it from ASP it works beautifully. However when I
compile the VB project into a DLL and register it, then run my asp page,
nothing happens. The DLL doesn't get called. It returns no error, no
nothing. It just gives me a blank page (instead of the encrypted string it
should give me)

Can anyone shed some light on this issue please?

Here's my code for the VB DLL:


Private Declare Function DmfDemoEncrypt Lib "email_encrypt.dll" (ByVal email
As String, ByVal s As String) As String


Public Function EncryptData(ByVal emailaddresses As String, ByVal
DataToEncrypt As String) As String

Dim strEmails As String
Dim strEncryptThisString As String
Dim strEncryptedData As String


strEncryptThisString = DataToEncrypt
strEmails = emailaddresses
strEncryptedData = (DmfDemoEncrypt(strEmails,
strEncryptThisString))




EncryptData = strEncryptedData



End Function

and the ASP code

<%

Dim WshShell,fso,cd,objRSServer,strEmails,strAll, strRetString


Set objRSServer = CreateObject("encrypt.clsEncryptData")

strEmails = leo@xxxxxxxxx,paul@xxxxxxxxx
cd = "this is encrypted email test"

on error resume next

'this is where the encryption happens. DLL is called and strAll now contains
an encrypted string
strAll=objRSServer.EncryptData(strEmails, cd)


if err<>"" then
response.write Err.number & " " & err.description
end if

response.write("<td>")

response.write "<TEXTAREA name='thetext' rows='50' cols='100'>"

response.write strAll
response.write("</TEXTAREA>")
response.write("</td>")



%>


Please help.....with whatever you can. No matter how crazy the idea just
post it. I am desperate


.



Relevant Pages

  • Re: can an asp page call a .NET DLL that...
    ... I have a set of asp pages that need to call a .NET DLL that does a Digital ... Signature XML to an xml doc. ... problem, as well as the method, but all it does is return an empty string ...
    (microsoft.public.dotnet.framework)
  • Re: Calling a VB DLL from ASP
    ... If email_encrypt.dll is not on the same folder as your DLL, ... >I asked this question in the ASP forum, but they only helped to a point. ... It just gives me a blank page (instead of the encrypted string it ... > Dim strEncryptThisString As String ...
    (microsoft.public.vb.com)
  • Re: Type mismatch calling a COM object developed in vb6
    ... page to the string type expected by the VB procedure. ... Couldn't he also just change the dim statement to ... an .ASP page, all the parameters for that method *must* ... Dim oUser as CUser ...
    (comp.lang.basic.visual.misc)
  • Re: COMException (0x80040212) - Mailversand
    ... Zudem handelt es sich um eine Seite die extra für den Test der ... Sie gibt mir alle Daten als String ... Ein Partner hatte vor Kurzem eine alte ASP Variante installiert und ich ...
    (microsoft.public.de.german.entwickler.dotnet.asp)
  • RE: query string encoding/decoding
    ... I've run a few simple tests looking at how query string encoding/decoding ... than it was in asp... ... encoding as a means of interpreting the input ... you get a collection when referencing the querystring ...
    (microsoft.public.dotnet.framework.aspnet)