Hi all
I'm having some trouble with pointers, and it's annoying the heck out of me. I'm creating a DLL in C++ and then using the calls in VB.
This is a small example to return the random value of 54, for vb to put in a textbox.
Working Code:
int ReturnValue(){
return 54;
}
Returns the memory address:
int ReturnValue(){
int ret=54;
return ret;
}
Call from VB:
public declare function ReturnValue lib "test.dll"() as long
sub Main()
Msgbox ReturnValue
end sub
This has been bugging me for a day now, so i would appreciate any help you could give (possibly alternate methods)
Thanks
~zix~
EDIT: hate UBB