我用WIN32 DLL建立DLL,目的是在VB与VC编译的.EXE程序之间进行实时传输数据,在网上查过首先创建一个有名的数据区。这在Visual C++中是使用data_seg pragma宏。 
我的程序: 
#include <string.h> 
#include <stdio.h>     
#pragma data_seg(".MYSEC") 
char MySharedData[4096]={0}; 
#pragma data_seg() 
    
void __stdcall SetData(LPSTR s) 

  strcpy(MySharedData, s); 

    
void __stdcall GetData(LPSTR s) 

  strcpy(s, MySharedData); 
} 但是报错很多,请高手指导啊