0

I am having an issue on deploying only. When I run program in Visual Studios everything works fine. When I deploy to the server, the program errors out. I have the E_BEPSET32.DLL within the folder where my .exe is however it fails find the E_BEPSET32.DLL.

Is there a way that you can specify the file path and DLL. If I hard code the file path and file name it works fine but I would rather not do that. I see that it can be done in C# but i am not sure how to convert this to VB

Specify the search path for DllImport in .NET

<DllImport("E_BEPSET32.DLL", EntryPoint:="EPDM_Open")>
    Public Shared Function EPDM_Open(DrvName As String, PortName As String, Type As Integer, DMAdd As IntPtr, ByRef PrnHandleAdd As IntPtr) As Integer
    End Function
CodeMonger
  • 347
  • 1
  • 4
  • 16
  • 1
    You probably forgot to copy the DLLs that this one needs, typically the C and/or C++ runtime DLLs. Run Dumpbin.exe /imports to see their names. Running the Epson installer on the target machine is best. – Hans Passant Jun 12 '19 at 17:07
  • 1
    Well, If i hard code the path to the DLL it works just fine – CodeMonger Jun 12 '19 at 17:21
  • 1
    Well, you already know that this doesn't make sense from your previous question about it. So that's not the problem. – Hans Passant Jun 12 '19 at 17:31

0 Answers0