我编译件败是怎么回事
exe程序文件cpp这个文件无法编译通过,哪位大哥帮看下哪错了???小弟初学,什么也不懂!#include "stdio.h"
#include "windows.h"
typedef int(*lpaddfun)(int,int);
 
int main(int argc,char *argv[])
{HINSTANCE hdll;
hdll=LoadLibrary("add.dll");lpaddfun add;add=(lpaddfun)GetProcAddress(hdll,"add");int ret=add(3,5);printf("%d",ret);
::FreeLibrary(hdll);return 0;
}dll文件
头文件add.h
 
#ifndef LIB_H
#define LIB_Hextern "C" __declspec(dllexport) int add(int x,int x);#endifdll主文件add.cpp#include "add.h"int add(int x,int y){
return (x+y);}