描述:
STDMETHODIMP MyCom::GetNum(int num, BSTR *bstr)
{
AFX_MANAGE_STATE(AfxGetStaticModuleState())
HANDLE hMap; //HANDLE 是定义好的结构
BJPMI *apoint; //BJPMI同上
char *str;
// Now Begin share Memory of input data
hMap = OpenFileMapping (FILE_MAP_ALL_ACCESS, // read/write access
FALSE , // no handle inhertance
"BJPEAMSINSH") ; // Named map
//assert (hMap) ;
// map view of max memory shared buffer
apoint = (BJPMI *)MapViewOfFile (hMap, // Mapping handle
FILE_MAP_ALL_ACCESS , // read/write access
0, // Hi address 32 Byte
0, // Lo address 32 Byte
sizeof(BJPMI)*PVA_SIZE*JIZU ) ; // Max size of map
sprintf(str,"%8.2f",apoint[0].pva_r);
CString str1;
str1 = str;
*bstr = str1.AllocSysString();
这是我的一个方法,为什么在ASP调用的时候,总是提示
出现一个意外错误: 'GetNum'
谁能帮我一下