Dll made in C using in vb.net

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • imavanloon
    New Member
    • Oct 2007
    • 1

    Dll made in C using in vb.net

    Hi there, I'am making an example program that uses a dll compiled i C(unmanaged).
    But i keep getting an error:"{"PInvok e restriction: cannot return variants."}

    I used following declare statement:

    Declare Function som Lib "dll_som.dl l" () as Integer


    the call is like this:"som" is a function in the dll.

    TextBox3.Text = som(A, B)

    Can enyone explain me how to do it properly!

    Thanks!
  • debasisdas
    Recognized Expert Expert
    • Dec 2006
    • 8119

    #2
    Question moved to .NET Forum.

    Comment

    Working...