几何尺寸与公差论坛

 找回密码
 注册
查看: 794|回复: 0

【转帖】sendkeys method, vista 64-bi

[复制链接]
发表于 2009-4-13 14:13:07 | 显示全部楼层 |阅读模式
sendkeys method, vista 64-bit
i have a macro that works in 32-bit xp, but hangs up in vista 64-bit. the place where it gets stuck uses the sendkeys method to transmit a shortcut key; this was necessary because the add-in i am using does not have an api call for this particular command.
in vista 64 i have found that sending the key works, but only if i leave off the portion of the command that determines the delay
sendkeys (["string"],[delay])
so the problem is that the action i am calling with the sent key, takes several seconds to complete. since the code will keep running, absent a programmed delay, i end up never seeing the completion of the action i am trying to take. worse; the macro calls this action 170 times, with several steps between each.
do any of you have any ideas about how to work with sendkeys in vista 64? is there a simple command i can use following sendkeys that would pause execution of the code long enough for my command to execute? (delay 15 seconds, kind of thing).
thanks in advance for the help!
danielle
danielle
thread.sleep(15000); // 15 second delay
您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|Archiver|小黑屋|几何尺寸与公差论坛

GMT+8, 2024-12-23 00:02 , Processed in 0.034666 second(s), 19 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表