How do I declare a pb dll in vb6

Everything else that doesn't fall into one of the other PB categories.
netmon
User
User
Posts: 12
Joined: Sun Jul 27, 2003 4:29 pm

How do I declare a pb dll in vb6

Post by netmon »

procedurecdll() and proceduredll() are not working.

ex.
procedurecdll savesnapshot(name.s)
endprocedure


vb declare is as follows. declare sub also.
Public Declare Function savesnapshot Lib "c:\temp\netdll.dll" (ByVal name As String)

when i use savesnapshot text1.text i get a bad calling convention. I can call a dll if it doesn't take parameters, but not this.

funny thing is the function works but i guess then its done calling the function, thats when if fails out.
netmon
User
User
Posts: 12
Joined: Sun Jul 27, 2003 4:29 pm

Post by netmon »

I solved this. It was the declare statement that was the culprit. I took out the public part and it seems to work not with no fuss. And I am using proceduredll not cdll.
Post Reply