AutoHotkey Community

It is currently May 27th, 2012, 12:32 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 8 posts ] 
Author Message
PostPosted: November 18th, 2009, 3:56 am 
Offline

Joined: November 18th, 2009, 3:45 am
Posts: 5
Brand new user here. I downloaded and installed AHK today at work using the .exe installer download. At the end of the installation, there is an option to open the README file, which I chose. I navigated to the Tutorial (quick start) section and followed the instructions on creating a script to open the google web page with the default web browser. I created the file, loaded it, pressed ctrl-space and it worked. I then continued to read the help file to learn more about the program. Along the way, I pressed ctrl-space again but surprisingly, nothing happened. I tried reloading the script, and still nothing. After playing around a little, it finally worked. At first I couldn't figure out why it worked one time but not others. But I finally narrowed it down to if the AHK Help file had the focus, the script would not work. 100% repeatability. I closed the help file and launched it again using the help option from the tray icon. This time it worked every time, as expected.

When I got home, I installed AHK on my home computer. At the last step, again I was given the option to open the README file. "Ahh", I wondered. Will it happen again? Sure enough, when the help file has the focus, the script won't run.

This is troublesome because new users like myself might be following along in the help file, and start having problems like I described above, and think the problems lie in the script.

I hope this helps.

By the way, AHK seems like a fantastic program. I can't wait to have some good scripts running on my computer.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 18th, 2009, 7:20 am 
This post should be in Ask for Help, not Bug Reports.

Though the poster does not say which code he tried, it sounds very much like he is testing the Send command, which sends key stokes only to the active window.


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: November 18th, 2009, 7:24 am 
Online
User avatar

Joined: December 26th, 2005, 4:40 pm
Posts: 8776
Quote:
Though the poster does not say which code he tried


MrGibbage wrote:
I navigated to the Tutorial (quick start) section and followed the instructions on creating a script to open the google web page with the default web browser. I created the file, loaded it, pressed ctrl-space and it worked.


but doc example uses win+space.
Code:
#space::Run www.google.com


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 18th, 2009, 12:39 pm 
Offline

Joined: November 18th, 2009, 3:45 am
Posts: 5
Well, I really think it is a bug. I followed the instructions exactly as they are presented in the help file (autohotkey.chm).
Download and install AutoHotkey.
Right-click an empty spot on your desktop or in a folder of your choice.
In the menu that appears, select New -> AutoHotkey Script.
Type a name for the file, ensuring that it ends in .ahk. For example: Test.ahk
Right-click the file and choose Edit Script.
On a new blank line, type the following:
#space::Run www.google.com

The hotkey and script work fine when the help file does not have the focus. If the help file has the focus, then it doesn't work. And to make matters ever more strange, this is only observed if the help file is launched as part of the installation process. If I manually open the help file now (by "now", I mean now that I have already installed the program and exited out of the installer), then the script runs fine.

I found this out "by accident" on my work computer, but then I was able to recreate it at home. I have not tried re-installing AHK to see if it happens on subsequent installations. All I know is it happens for sure on the first installation (at least two times for me, anyways).

I hope that helps.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 18th, 2009, 12:40 pm 
Offline

Joined: November 18th, 2009, 3:45 am
Posts: 5
Whoops, I meant to say win+space.

SKAN wrote:
Quote:
Though the poster does not say which code he tried


MrGibbage wrote:
I navigated to the Tutorial (quick start) section and followed the instructions on creating a script to open the google web page with the default web browser. I created the file, loaded it, pressed ctrl-space and it worked.


but doc example uses win+space.
Code:
#space::Run www.google.com


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 18th, 2009, 12:51 pm 
Online
User avatar

Joined: December 26th, 2005, 4:40 pm
Posts: 8776
MrGibbage wrote:
Download and install AutoHotkey.
Right-click an empty spot on your desktop or in a folder of your choice.
In the menu that appears, select New -> AutoHotkey Script.
Type a name for the file, ensuring that it ends in .ahk. For example: Test.ahk
Right-click the file and choose Edit Script.
On a new blank line, type the following:
#space::Run www.google.com


I tried exactly as above, but I am unable to reproduce the effect.
Something is strange on your system.. If possible, try on an another machine.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 18th, 2009, 1:22 pm 
Offline

Joined: November 18th, 2009, 3:45 am
Posts: 5
Wow, this happened to me twice, on two different machines, with two different operating systems. Strange. I've got one more computer I can try it on. I'll try later tonight.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 19th, 2009, 2:21 am 
Offline

Joined: November 18th, 2009, 3:45 am
Posts: 5
I just tried it on a third computer and I have the exact same results. Here are the steps to recreate the symptoms:
1. Download the latest AHK installer from http://www.autohotkey.com/download/Auto ... nstall.exe
2. Install using defaults.
3. At the end of the installation, ensure the option to open the README file is checked. Click finish and the documentation will launch.
4. Click on the getting started option from the menu.
5. Follow the steps to create the google launcher script.
#space::Run www.google.com
6. Load the script by double-clicking it.
7. Click the help file to ensure it has the focus.
7. Press win+space
8. Observe that if the help file has the focus, the web browser does NOT launch the google web site. I have noticed that something happens, but I can't tell what (open windows are flashing or something... really strange). Sometimes the help file will lose the focus at this point, and pressing win+space a second will work correctly.

Comments
Any time the help file has focus, the script will not properly execute. If the help file does not have the focus, the script will execute properly. If you close down the help file altogether, and then launch it again by other means, the script will execute even if the help file has focus, so this seems to be a one-time deal.

On my computer at home, I tried reinstalling AHK, and going through the steps again, and it did indeed exhibit the same symptoms described above. So this does not seem to be limited to the very first installation. I have not tested the reinstallation on all of my computers.


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: Bing [Bot], chaosad, Exabot [Bot], Google Feedfetcher, jrav and 20 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