Build this as dll:
// testDll.c
int __declspec( dllexport ) __cdecl SampleFunction(int a, int b)
{
return a * b;
}
#include <stdio.h>
#pragma comment(lib, "TestDll.lib")
int __declspec( dllexport ) __cdecl SampleFunction(int a, int b);
int main(int argc, char **argv)
{
printf("result: %d\n", SampleFunction(40, 2));
return 0;
}