|
我第一次用C++调用Windows API 来写窗口,但是我很郁闷,,我这个怎么米有窗口啊,,,大哥大们给帮忙看下。谢谢!
程序代码:
#include <windows.h>
#include <stdio.h>
LRESULT CALLBACK WinLogerPro(
HWND hKeyloger, // handle to window
UINT uMsg, // message identifier
WPARAM wParam, // first message parameter
LPARAM lParam // second message parameter
);
int WINAPI WinMain(
HINSTANCE klg, // handle to current instance
HINSTANCE hPrevInstance, // handle to previous instance
LPSTR lpCmdLine, // command line
int nCmdShow // show state
)
{
WNDCLASS keyloger;
keyloger.style=CS_HREDRAW | CS_VREDRAW;
keyloger.lpfnWndProc=WinLogerPro;
keyloger.cbClsExtra=0;
keyloger.cbWndExtra=0;
keyloger.hInstance=klg;
keyloger.hIcon=LoadIcon(NULL,IDI_ERROR);
keyloger.hCursor=LoadCursor(NULL,IDC_CROSS);
keyloger.hbrBackground=(HBRUSH)GetStockObjec |
|