January 8th, 2013, 06:34 AM
I need to reuse a script in VB6 that decrypts and encrypts to be able to use it in VB.NET projects. I made as an ActiveX DLL, I tried referencing it but .NET won't accept it. I tried DLLImport but i'm getting 'System.EntryPointNotFoundException' Error.
I tried adding a module in the dll then recompiling it again and had a startup of SubMain but still the same error exists.
Below is my code using VB.NET:
Public Class Form1
<DllImport("prj_MFEE_CRYPT_DECRYPT.dll", SetLastError:=True, CharSet:=CharSet.Auto)> _
Private Shared Function Crypt(ByVal s_text As String) As String
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim c_str As String
c_str = Crypt("phoenix")
Anyone knows what I'm missing?