AutoHotkey Community

It is currently May 26th, 2012, 7:59 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 17 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: KeyWait Pause
PostPosted: June 12th, 2008, 3:15 pm 
Hi,

I have following problem, when I use command KeyWait with key "Break" or "Pause" or "CTRLBREAK" it does not function each time, I have nearly always to press Pause sometimes 2 or more times till it is accepted for example following code:
Code:
KeyWait, Pause, D
MsgBox, You pressed Pause Key


Can anyone test and confirm having the same problem, is it a bug?

Thanks in advance.


Report this post
Top
  
Reply with quote  
 Post subject: Re: KeyWait Pause
PostPosted: June 12th, 2008, 4:23 pm 
Online
User avatar

Joined: December 26th, 2005, 4:40 pm
Posts: 8776
BIOSRAM wrote:
Can anyone test and confirm having the same problem, is it a bug?


Your code works fine for me. Maybe your key is faulty?
Have you confirmed it with a hotkey?

Code:
Pause::MsgBox, Pause key!


:)

_________________
URLGet - Internet Explorer based Downloader
StartEx - Portable Shortcut Link


Report this post
Top
 Profile  
Reply with quote  
 Post subject: KeyWait Pause
PostPosted: June 12th, 2008, 9:35 pm 
Thanks SKAN, you are right, this is a problem with my keyboard, I never thought it might be a problem with keyboard.

Thanks for quick reply.


Report this post
Top
  
Reply with quote  
 Post subject: KeyWait Pause
PostPosted: June 12th, 2008, 10:14 pm 
Hi again,

looks like the key is not the problem.
I have now tried a hotkey, this works fine but KeyWait still does not work very often.

Kan you try following 2 examples:
Code:
Loop
{
KeyWait, CTRL, D
ToolTip, Count: %A_Index%
}

and
Code:
Loop
{
KeyWait, PrintScreen, D
ToolTip, Count: %A_Index%
}


You can use any other key than CtrlBreak, Break or Pause for the second example.

Now press and hold the key.
With Pause, Break and CtrlBreak keys tooltip will not continue to count, you will need to release and press Pause again than it will count a little and stop again, other than any other key where you can hold the key and it will continue to count until you release the key.

Can you please test and confirm?


Report this post
Top
  
Reply with quote  
 Post subject: Re: KeyWait Pause
PostPosted: June 12th, 2008, 11:28 pm 
Online
User avatar

Joined: December 26th, 2005, 4:40 pm
Posts: 8776
BIOSRAM wrote:
Code:
Loop
{
KeyWait, PrintScreen, D
ToolTip, Count: %A_Index%
}


Can you please test and confirm?


That code works fine for me. There is something peculiar about your keyboard, I guess.

:)

_________________
URLGet - Internet Explorer based Downloader
StartEx - Portable Shortcut Link


Report this post
Top
 Profile  
Reply with quote  
 Post subject: KeyWait Pause
PostPosted: June 13th, 2008, 10:57 am 
Hi SKAN,

and what about Pause Key? PrintScreen was only to show how it should work:

Code:
Loop
{
KeyWait, Pause, D
ToolTip, Count: %A_Index%
}


Does it work for you as well? I have tried on several computers and it does not work.[/b]


Report this post
Top
  
Reply with quote  
 Post subject: Re: KeyWait Pause
PostPosted: June 14th, 2008, 10:13 am 
Online
User avatar

Joined: December 26th, 2005, 4:40 pm
Posts: 8776
BIOSRAM wrote:
and what about Pause Key?


Works normal.. as every other key. :)

_________________
URLGet - Internet Explorer based Downloader
StartEx - Portable Shortcut Link


Report this post
Top
 Profile  
Reply with quote  
 Post subject: KeyWait Pause
PostPosted: June 14th, 2008, 10:43 am 
Hi SKAN,

thans for testing, so when you press and hold Pause for my example loop continues to run and count is growing?

That is weird, I have now tested it on 3 computers and it does definitely not work. Do you possibly have another computer where you can test?

I will test that key on other computers and will report if it worked.

Can anybody else test it and confirm possibly?

Code:
Loop
{
KeyWait, Pause, D
ToolTip, Count: %A_Index%
}


Thank you.


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: June 14th, 2008, 12:28 pm 
Offline

Joined: June 14th, 2008, 11:46 am
Posts: 5
Those scripts work fine on my computer, BIOSRAM.
There may be some other program using those keys ?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 14th, 2008, 1:53 pm 
Do you use the latest version of AutoHotkey? And: it might be that your keyboard simply needs physical cleaning...


Report this post
Top
  
Reply with quote  
 Post subject: KeyWait Pause
PostPosted: June 14th, 2008, 3:47 pm 
Thanks for testing.

This is really weird, I do not think it is my key and I also have the latest version of AutoHotkey.

I have now tested it on 1 computers and 2 notebooks, all with different builds of windows xp professional, but it does not work on all of them.

When I run this code I have to press Pause again and again to make the loop continue, on my older notebook I need to press it more than 10 times till the script continues but it always stops on all computers:
Code:
Loop
{
 KeyWait, Pause, D
 ToolTip, Count: %A_Index%
}



A_Index grows for around 100++ but always stops.

I will continue to test it on other computers and will reply soon.

Are you also using win xp prof?


Report this post
Top
  
Reply with quote  
 Post subject: KeyWait Pause
PostPosted: June 14th, 2008, 4:12 pm 
I have now tested it with a USB Keyboard and it works, very odd.

I tried the same with a usb/ps2 converter and normal keyboard and it does not work.

Must be something with the keyboard.

SKAN, Vade, n-l-i-d, are you using a PS2 Keyboard?


Report this post
Top
  
Reply with quote  
 Post subject: Re: KeyWait Pause
PostPosted: June 14th, 2008, 6:00 pm 
Online
User avatar

Joined: December 26th, 2005, 4:40 pm
Posts: 8776
BIOSRAM wrote:
SKAN, Vade, n-l-i-d, are you using a PS2 Keyboard?


Oh! No.. I tested it with USB KB.. I will try it with PS2 and reply again.

:)

_________________
URLGet - Internet Explorer based Downloader
StartEx - Portable Shortcut Link


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 14th, 2008, 7:04 pm 
Offline

Joined: November 2nd, 2004, 2:43 pm
Posts: 1019
Location: London, UK
Testing on mine and looking at the key history suggests that at least on my system the pause key does not produce auto repeat key strokes.

FYI I am using a laptop with built in PS/2 keyboard.

_________________
Steve F AKA Superfraggle

http://r.yuwie.com/superfraggle


Report this post
Top
 Profile  
Reply with quote  
 Post subject: KeyWait Pause
PostPosted: June 14th, 2008, 11:00 pm 
That is right Superfraggle

it sends the key up even it is still down, so when I press and hold Pause and press F5 for refreshing it shows that key released.


Report this post
Top
  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 17 posts ]  Go to page 1, 2  Next

All times are UTC [ DST ]


Who is online

Users browsing this forum: Leef_me, poserpro, sjc1000, Tilter_of_Windmills and 62 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group