About CWnd Error
-
Hi, I created dll and trying to export a function which in turn calls InvokeHelper function,But my dll is created using win32 dynamic library it is not recognizing InvokeHelper,so i included the macros, _AFX_NO_OCC_SUPPORT and AFX_CDECL.Now it is showing error as, error C2061: syntax error : identifier 'CWnd'.What i have to do.Please help me...:(( Siddharth
-
Hi, I created dll and trying to export a function which in turn calls InvokeHelper function,But my dll is created using win32 dynamic library it is not recognizing InvokeHelper,so i included the macros, _AFX_NO_OCC_SUPPORT and AFX_CDECL.Now it is showing error as, error C2061: syntax error : identifier 'CWnd'.What i have to do.Please help me...:(( Siddharth
Include
afxwin.h
, remove statement#include <windows.h>
, if there is any.siddharthsan wrote:
_AFX_NO_OCC_SUPPORT and AFX_CDECL
I wonder, why you needed to use this?
Prasad Notifier using ATL | Operator new[],delete[][^]
-
Include
afxwin.h
, remove statement#include <windows.h>
, if there is any.siddharthsan wrote:
_AFX_NO_OCC_SUPPORT and AFX_CDECL
I wonder, why you needed to use this?
Prasad Notifier using ATL | Operator new[],delete[][^]
If I include afxwin.h it showing the following error, fatal error C1189: #error : WINDOWS.H already included. MFC apps must not #include What i have to do... Siddharth
-
If I include afxwin.h it showing the following error, fatal error C1189: #error : WINDOWS.H already included. MFC apps must not #include What i have to do... Siddharth
Remove line #include <windows>, if there is any.
Prasad Notifier using ATL | Operator new[],delete[][^]
-
Remove line #include <windows>, if there is any.
Prasad Notifier using ATL | Operator new[],delete[][^]
I removed windows.h from stdafx.h and included afxwin.h in my header file.Now it is not recognizing the InvokeHelper and it's parameters.Giving error as error C2065: 'InvokeHelper' : undeclared identifier error C2065: 'DISPATCH_METHOD' : undeclared identifier error C2065: 'VT_EMPTY' : undeclared identifier What would be the problem... Siddahrth
-
Hi, I created dll and trying to export a function which in turn calls InvokeHelper function,But my dll is created using win32 dynamic library it is not recognizing InvokeHelper,so i included the macros, _AFX_NO_OCC_SUPPORT and AFX_CDECL.Now it is showing error as, error C2061: syntax error : identifier 'CWnd'.What i have to do.Please help me...:(( Siddharth
How do you expect to use an OCC_SUPPORT method by using the _AFX_NO_OCC_SUPPORT macro to ommit OCC support in the MFC code?? Get rid of that macro!
*EDIT* You probably shouldn't be messing with AFX_CDECL either unless you know what you're doing.
Look at the declaration for CWnd::InvokeHelper()...#ifndef _AFX_NO_OCC_SUPPORT
// OLE control wrapper functions
COleControlSite* GetOleControlSite(UINT idControl) const;
void AFX_CDECL InvokeHelper(DISPID dwDispID, WORD wFlags,
...See why it won't work with that macro? :) Mark
"If you can dodge a wrench, you can dodge a ball."