【火山pc】封装SendMessage进行消息发送
本帖最后由 1185907650 于 2021-2-14 15:00 编辑一、界面布局
添加组合框、编辑框、按钮、单选框
https://www.lkuaiy.com/image/editor/16013057914421.png
https://www.lkuaiy.com/image/editor/16013058009586.png
二、封装SendMessage函数
①查找函数
**搜索得到函数原型:SendMessage(HWND hWnd,UINT Msg,WPARAM wParam,LPARAM lParam)
参数:
hWnd:其窗口程序将接收消息的窗口的句柄
Msg:指定被发送的消息
wParam:指定附加的消息指定信息
IParam:指定附加的消息指定信息
②封装
Ctrl M新建方法,如下图
https://www.lkuaiy.com/image/editor/16013058155332.png
三、添加事件
https://www.lkuaiy.com/image/editor/16013058263678.png
https://www.lkuaiy.com/image/editor/16013058351946.png
四、发送消息
https://www.lkuaiy.com/image/editor/16013058504400.png
https://www.lkuaiy.com/image/editor/16013058586248.png
https://www.lkuaiy.com/image/editor/16013058656410.png
五、演示效果
https://www.lkuaiy.com/image/editor/16013058816218.gif
本文章转载自利快云,点击阅读原文:https://www.lkuaiy.com/ArticleForumInsidePage?id=16013409168192
推广火山义不容辞 推广火山,义不容辞 推广火山,义不容辞 推广火山,义不容辞 推广火山,义不容辞 推广火山,义不容辞 推广火山, 推广火山,义不容辞 推广火山,义不容辞
页:
[1]
2