Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何MB_OK|MB_ICONINFORMATION在 Windows API 中创建一个简单的 MessageBox 并在诸如“Z”之类的按键时关闭它?
MB_OK|MB_ICONINFORMATION
可以使用以下代码创建消息框:
#include<windows.h> int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nCmdShow){ MessageBox(NULL,"Good Bye, Cruel World!","Note",MB_OK|MB_ICONINFORMATION); return 0; }
使用钩子。