惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Know Your Adversary
Know Your Adversary
云风的 BLOG
云风的 BLOG
Recent Announcements
Recent Announcements
F
Fortinet All Blogs
B
Blog
罗磊的独立博客
宝玉的分享
宝玉的分享
Vercel News
Vercel News
Martin Fowler
Martin Fowler
N
Netflix TechBlog - Medium
P
Proofpoint News Feed
T
Threatpost
Security Latest
Security Latest
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
Stack Overflow Blog
Stack Overflow Blog
I
Intezer
P
Privacy International News Feed
D
Docker
月光博客
月光博客
博客园 - 三生石上(FineUI控件)
M
MIT News - Artificial intelligence
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Recent Commits to openclaw:main
Recent Commits to openclaw:main
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
L
Lohrmann on Cybersecurity
Google DeepMind News
Google DeepMind News
The Last Watchdog
The Last Watchdog
A
Arctic Wolf
IT之家
IT之家
S
SegmentFault 最新的问题
S
Securelist
博客园 - 叶小钗
N
News and Events Feed by Topic
F
Full Disclosure
Security Archives - TechRepublic
Security Archives - TechRepublic
Engineering at Meta
Engineering at Meta
Hacker News: Ask HN
Hacker News: Ask HN
博客园 - Franky
GbyAI
GbyAI
AI
AI
Y
Y Combinator Blog
WordPress大学
WordPress大学
Latest news
Latest news
Microsoft Security Blog
Microsoft Security Blog
人人都是产品经理
人人都是产品经理
N
News | PayPal Newsroom
The Cloudflare Blog
www.infosecurity-magazine.com
www.infosecurity-magazine.com
I
InfoQ

博客园 - jingleguo

[zz]软件测试专业术语 word分栏时脚注强制分页问题解决 安装JDK和TOMCAT并配置环境变量的过程 - jingleguo - 博客园 Thinkpad鼠标在Chrome中无法使用滚轮 [zz]第五套人民币发行冠号 SourceForge镜像 How Can You Buy or Sell The Sky?[zz] Python设置默认语言编码 china-pub返回的错误网页 - jingleguo - 博客园 X61 T61 休眠后自动重启与耗电问题 自题 'You've got to find what you love,' Jobs says 百度千万别做邮箱 察传 赋得自君之出矣 用逻辑来骗MM和在论坛上骗钱 Google 的午餐 Java使用Scream流读入并输出文件示例 集句
使用VC向Windows发送消息代码示例
jingleguo · 2007-09-23 · via 博客园 - jingleguo

BOOL CheckMessageQueue() {
  MSG msg;
  
while(PeekMessage(&msg, NULL, 00, PM_REMOVE)){
    
if(msg.message==WM_QUIT)
    
return FALSE;
    TranslateMessage(
&msg);
    DispatchMessage(
&msg);
  }

  
return TRUE;
}


BOOL SentSz(
char* sz) {
  
for ( DWORD j = 0; sz[j]; j++{
    keybd_event(sz[j], MapVirtualKey(sz[j],
0),
      
00);
    CheckMessageQueue();
    keybd_event(sz[j], MapVirtualKey(sz[j],
0), 
      KEYEVENTF_KEYUP, 
0);
    CheckMessageQueue();
  }

  
return TRUE;
}


void Proc(){
    SentSz(
"test");
}