我在声明中这样写的
class CDLLDloadApp : public CWinApp
{public:
CDLLDloadApp();
CAppConfig m_AppConfig;
CProject m_Project;
FUNC_PROTOTYPE CAppConfig &getAppConfig();
FUNC_PROTOTYPE CProject &getProject();
而实现过程是这样写的
#define FUNC_PROTOTYPE extern "C" _declspec(dllexport)
#include "stdafx.h"
#include "DLLDload.h"
#include "utility/cipher.h"
#include "utility/des.inl"
#include "dom/project.h"
#include "dom/workshop.h"
#include "dom/recipe_list.h"
#include "dom/recipe.h"
#include "dom/appcfg.h"
CAppConfig &getAppConfig()
{
return m_AppConfig;
}
CProject &getProject()
{
return m_Project;
} bool IsDownLoad(long recipeno,CString recipename)
{
}
编译时出现这样错误
LLDload.cpp
e:\program_flies\recipe program\dlldload\dlldload.h(41) : error C2146: syntax error : missing ';' before identifier 'CAppConfig'
e:\program_flies\recipe program\dlldload\dlldload.h(41) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
e:\program_flies\recipe program\dlldload\dlldload.h(42) : error C2146: syntax error : missing ';' before identifier 'CProject'
e:\program_flies\recipe program\dlldload\dlldload.h(42) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
e:\program_flies\recipe program\dlldload\dlldload.h(44) : error C2146: syntax error : missing ';' before identifier 'bool'
e:\program_flies\recipe program\dlldload\dlldload.h(44) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
E:\Program_Flies\Recipe Program\DLLDload\DLLDload.cpp(96) : error C2065: 'm_AppConfig' : undeclared identifier
E:\Program_Flies\Recipe Program\DLLDload\DLLDload.cpp(100) : error C2065: 'm_Project' : undeclared identifier
project.cpp
e:\program_flies\recipe program\dlldload\dlldload.h(41) : error C2146: syntax error : missing ';' before identifier 'CAppConfig'
e:\program_flies\recipe program\dlldload\dlldload.h(41) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
e:\program_flies\recipe program\dlldload\dlldload.h(42) : error C2146: syntax error : missing ';' before identifier 'CProject'
e:\program_flies\recipe program\dlldload\dlldload.h(42) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
e:\program_flies\recipe program\dlldload\dlldload.h(44) : error C2146: syntax error : missing ';' before identifier 'bool'
e:\program_flies\recipe program\dlldload\dlldload.h(44) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
Generating Code...
执行 cl.exe 时出错.
请问是怎么回事,那块有问题
class CDLLDloadApp : public CWinApp
{public:
CDLLDloadApp();
CAppConfig m_AppConfig;
CProject m_Project;
FUNC_PROTOTYPE CAppConfig &getAppConfig();
FUNC_PROTOTYPE CProject &getProject();
而实现过程是这样写的
#define FUNC_PROTOTYPE extern "C" _declspec(dllexport)
#include "stdafx.h"
#include "DLLDload.h"
#include "utility/cipher.h"
#include "utility/des.inl"
#include "dom/project.h"
#include "dom/workshop.h"
#include "dom/recipe_list.h"
#include "dom/recipe.h"
#include "dom/appcfg.h"
CAppConfig &getAppConfig()
{
return m_AppConfig;
}
CProject &getProject()
{
return m_Project;
} bool IsDownLoad(long recipeno,CString recipename)
{
}
编译时出现这样错误
LLDload.cpp
e:\program_flies\recipe program\dlldload\dlldload.h(41) : error C2146: syntax error : missing ';' before identifier 'CAppConfig'
e:\program_flies\recipe program\dlldload\dlldload.h(41) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
e:\program_flies\recipe program\dlldload\dlldload.h(42) : error C2146: syntax error : missing ';' before identifier 'CProject'
e:\program_flies\recipe program\dlldload\dlldload.h(42) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
e:\program_flies\recipe program\dlldload\dlldload.h(44) : error C2146: syntax error : missing ';' before identifier 'bool'
e:\program_flies\recipe program\dlldload\dlldload.h(44) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
E:\Program_Flies\Recipe Program\DLLDload\DLLDload.cpp(96) : error C2065: 'm_AppConfig' : undeclared identifier
E:\Program_Flies\Recipe Program\DLLDload\DLLDload.cpp(100) : error C2065: 'm_Project' : undeclared identifier
project.cpp
e:\program_flies\recipe program\dlldload\dlldload.h(41) : error C2146: syntax error : missing ';' before identifier 'CAppConfig'
e:\program_flies\recipe program\dlldload\dlldload.h(41) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
e:\program_flies\recipe program\dlldload\dlldload.h(42) : error C2146: syntax error : missing ';' before identifier 'CProject'
e:\program_flies\recipe program\dlldload\dlldload.h(42) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
e:\program_flies\recipe program\dlldload\dlldload.h(44) : error C2146: syntax error : missing ';' before identifier 'bool'
e:\program_flies\recipe program\dlldload\dlldload.h(44) : error C2501: 'FUNC_PROTOTYPE' : missing storage-class or type specifiers
Generating Code...
执行 cl.exe 时出错.
请问是怎么回事,那块有问题
解决方案 »
- 各位高手,我用VC6.0派生个ClistCtrl类,为什么LVN_ENDSCROLL不响应
- 怎么调用IDocHostUIHandler接口ShowContextMenu()函数举个例子阿
- 用什么函数可以确定在一块内存中是否存在一字符串?
- CheckList如何实现
- 不用线程,如何退出循环?
- 在COM+的事件服务中怎么创建一个事件类,它和普通的COM组件有什么不同。
- 高分求教,在线等待:使用dcom创建实例时,提示:由于另一个程序正在运行,要求的功能无法实现
- 请问一下,用WSASendTo()函数怎么发送一个结构体类型的数据?
- 如何使标题栏上的"X"按钮,变灰?
- 有高手吗!!!!?对于API函数writefile()在对串口进行操作过程中,在NT及2000下与Win98/95有什么不一样吗?
- 几个子对话框之间交换数据
- 奇怪的filter
#include "stdafx.h"
#include "DLLDload.h"
#include "utility/cipher.h"
#include "utility/des.inl"
#include "dom/project.h"
#include "dom/workshop.h"
#include "dom/recipe_list.h"
#include "dom/recipe.h"
#include "dom/appcfg.h"
上面的就是啊