Using DLL.CallFunction on a .NET assembly

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • professioras
    Forum Member
    • Jan 2008
    • 8

    Using DLL.CallFunction on a .NET assembly

    Hi,

    I am using DLL.CallFunction on a .NET assembly that I created with VS2005 with C#. I add that assembly in the primer files and then I simply call one of its static functions. The assembly is COM visible (by checking the "make assembly COM-Visible" option in VS).

    I always get the error 2401 "Failed to find the specified function within the DLL." from SF7.0.

    Just for testing purposes I also created another exe file using VS2005 that is using the .NET assembly, placed it to the primer files as well and run that using the File.Run function and all was fine. So SF7.0 cannot recognize my assembly but the test application can.

    Another thing I tried is to add my assembly to the archive and in the file properties in the Advanced tab I pressed the "Test" button in the OLE/ActiveX group box. I got the error message "The file does not support DLLRegisterServer (ActiveX self-registration)". I am not sure if I need to register my assembly in order to call functions from it using DLL.CallFunction.

    Thanks in advance.
  • Adam
    Indigo Rose Staff Member
    • May 2000
    • 2149

    #2
    .net dlls do not act the same way as other dll files. Read this thread where this has been discussed before.

    Adam Kapilik

    Comment

    • professioras
      Forum Member
      • Jan 2008
      • 8

      #3
      Thanks Adam, I had read that post before I send this post. Since it was more than a year old I hoped that someone else has found a solution. I guess not... I'll switch to C++ then... :yes

      Comment

      Working...
      X