INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: calling an external Function in VB  (Read 1720 times)

josephjohn100

  • Regular Member
  • Member
  • *
  • Posts: 1
  • Change this by choosing profile
calling an external Function in VB
« on: June 07, 2004, 04:25:15 pm »

I'm calling an external Function from a DLL(written in VC++) from VB.
The function is returning a long value.

I'm calling this function Using a Call function. and trying to get the return values using
if conditions on Err.Number like
   If Err.Number = 0 Then   'like this

But Err.Number is not getting the values if the function returns fail,or cancel value etc.

Is there any other method we can get this value.
I cannot use a
    retval = FunctionName
as in the object browser shows my function as

Sub LogonUser()
    Member of SECURITYLib.Sec    
    Logon a user.

Is there any other method we can get this value.?
Logged

RhinoBanga

  • Citizen of the Universe
  • *****
  • Posts: 1703
  • Developer
Re:calling an external Function in VB
« Reply #1 on: June 08, 2004, 12:41:24 am »

Try err.LastDllError
Logged
Pages: [1]   Go Up