Loading ...
Sorry, an error occurred while loading the content.

Re: How about Press Ctrl key before next operate?

Expand Messages
  • Dennis K. Paulsen
    You can try: SendRawKey(VK_LCONTROL, KEYEVENTF_EXTENDEDKEY); # press SendRawKey(VK_LCONTROL, KEYEVENTF_EXTENDEDKEY | KEYEVENTF_KEYUP); # release Regards,
    Message 1 of 2 , Apr 29, 2005
    • 0 Attachment
      You can try:

      SendRawKey(VK_LCONTROL, KEYEVENTF_EXTENDEDKEY); # press
      SendRawKey(VK_LCONTROL, KEYEVENTF_EXTENDEDKEY | KEYEVENTF_KEYUP); #
      release

      Regards,
      Dennis

      --- In perlguitest@yahoogroups.com, liu xiaolei <guguqiaqia@y...>
      wrote:
      >
      > hi,
      > How about Press Ctrl key?
      > I write a function ,please look this:
      >
      > # 1 start x,2 start y,3 end x,4 end y
      > sub CtrlClickTwo
      > {
      > MouseMoveAbsPix($_[0],$_[1]);
      > SendMouse("{LEFTCLICK}");
      > sleep 1;
      > SendRawKey(VK_CONTROL,0);
      > sleep 1;
      > MouseMoveAbsPix($_[2],$_[3]);
      > SendMouse("{LEFTCLICK}");
      > sleep 1;
      > SendRawKey(VK_CONTROL,KEYEVENTF_KEYUP);
      > }
      > But when i use it,Ctrl key cann't press down.
      > Why ?
      >
      > Thanks,
      > Liu xiaolei
      >
      > _________________________________________________________
      > Do You Yahoo!?
      > 150ÍòÇúMP3·è¿ñËÑ£¬´øÄú´³ÈëÒôÀÖµîÌÃ
      > http://music.yisou.com/
      > ÃÀÅ®Ã÷ÐÇÓ¦Óо¡ÓУ¬ËѱéÃÀͼ¡¢ÑÞͼºÍ¿áͼ
      > http://image.yisou.com
      > 1G¾ÍÊÇ1000Õ×£¬ÑÅ»¢µçÓÊ×ÔÖúÀ©ÈÝ£¡
      >
      http://cn.rd.yahoo.com/mail_cn/tag/1g/*http://cn.mail.yahoo.com/event
      /mail_1g/
    Your message has been successfully submitted and would be delivered to recipients shortly.