【这样为什么会编译错误????】
我用VC6通过“Win32 Application”下的“A typical ‘Hello World’application”模板生成了一个Project。
其中的InitInstance函数源码如下:
BOOL InitInstance(HINSTANCE hInstance, int nCmdShow)
{
HWND hWnd;
hInst = hInstance; // Store instance handle in our global variable
hWnd = CreateWindow(szWindowClass, szTitle, WS_OVERLAPPEDWINDOW,
CW_USEDEFAULT, 0, CW_USEDEFAULT, 0, NULL, NULL, hInstance, NULL);
if (!hWnd)
{
return FALSE;
}
ShowWindow(hWnd, nCmdShow);
UpdateWindow(hWnd);
//我定义的一个变量
CBitmap m_try;
return TRUE;
}
就在这加了一行代码,其他的都是自动生成的。
可为什么在编译的时候就有错,说CBitmap并没有定义,请问,这是怎么一回事??
如果我要定义这样一个变量,还应该怎么做???