VBA
Declare Function Foo Lib "test.dll" (ByRef result As Long) As Long
VC++
extern "C" __declspec(dllexport) void __stdcall Foo(long &result);
VBA
Declare Function Foo Lib "test.dll" (ByRef result As Long) As Long
VC++
extern "C" __declspec(dllexport) void __stdcall Foo(long &result);