AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Alt+M+S opens say, a website
Goto page 1, 2  Next
 
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
Mikesnm



Joined: 15 Oct 2008
Posts: 25
Location: SoCal

PostPosted: Sat Nov 15, 2008 3:27 pm    Post subject: Alt+M+S opens say, a website Reply with quote

Two questions here. Can I have a series of letters do something. Say hold down alt and tap m and then tap s. Then also how to open a certain web page?
Thanks!
Back to top
View user's profile Send private message
tank



Joined: 21 Dec 2007
Posts: 3700
Location: Louisville KY USA

PostPosted: Sat Nov 15, 2008 3:47 pm    Post subject: Reply with quote

http://www.autohotkey.com/ wrote:
Introduction
AutoHotkey is a free, open-source utility for Windows. With it, you can:

Automate almost anything by sending keystrokes and mouse clicks. You can write a mouse or keyboard macro by hand or use the macro recorder.
Create hotkeys for keyboard, joystick, and mouse. Virtually any key, button, or combination can become a hotkey.
Expand abbreviations as you type them. For example, typing "btw" can automatically produce "by the way".
Create custom data-entry forms, user interfaces, and menu bars. See GUI for details.
Remap keys and buttons on your keyboard, joystick, and mouse.
Respond to signals from hand-held remote controls via the WinLIRC client script.
Run existing AutoIt v2 scripts and enhance them with new capabilities.
Convert any script into an EXE file that can be run on computers that don't have AutoHotkey installed.
Getting started might be easier than you think. Check out the quick-start tutorial.

i suggest starting with the front page of this site
_________________

We are troubled on every side‚ yet not distressed; we are perplexed‚
but not in despair; Persecuted‚ but not forsaken; cast down‚ but not destroyed;
Back to top
View user's profile Send private message
TechOpus



Joined: 02 Oct 2008
Posts: 13

PostPosted: Sat Nov 15, 2008 5:51 pm    Post subject: Reply with quote

If someone knows the answer to Mikesnm's inquiry, please respond. I did read the manual, specifically the Hotkeys page and could not find the answer.

Thank you.
Back to top
View user's profile Send private message
Conquer



Joined: 27 Jun 2006
Posts: 385
Location: Canada

PostPosted: Sat Nov 15, 2008 7:08 pm    Post subject: Reply with quote

Check the index (in the ahk help file) on these topics:

Hotkeys - You probably already figured this out
Run - To open websites or documents
Variables - For knowing if the user has pressed the first hotkey.

For the mutliple hotkey thing, here's some simple code.

Code:
!1::  ; Alt+1
Hotkey1 = True
return

!2::  ; Alt+2
If Hotkey1 = True   ; First hotkey has been pressed
{
  Hotkey1 = False   ; Reset the hotkeys
  Run http://www.google.ca
  return
}
return

(untested)
Back to top
View user's profile Send private message
Mikesnm



Joined: 15 Oct 2008
Posts: 25
Location: SoCal

PostPosted: Sun Nov 16, 2008 2:01 am    Post subject: Reply with quote

I have read the manual several times as well, and before I post any question, I review it. I'm sure I miss a lot, a lot that I don't get- sorry. It's difficult for a layman. A lot of us are not programmers; just people who like this program, and see a forum called 'ask for help', and then ask. This is the second time I get some insinuation that I'm not trying to figure it out myself first. The last guy said RTFM- classy. If someone doesn't want to answer, then don't. It takes less time to just leave an answer if it's easy for you. I am learning with each response I get, and I'm really trying.

But thanks for the code you provided, I appreciate it.
Back to top
View user's profile Send private message
Mikesnm



Joined: 15 Oct 2008
Posts: 25
Location: SoCal

PostPosted: Sun Nov 16, 2008 2:12 am    Post subject: Thanks! Reply with quote

hey Conquer
Your code works great! Thanks!

But
you mean they got Google in Canada even?
Back to top
View user's profile Send private message
NotLoggedIn-Conquer
Guest





PostPosted: Sun Nov 16, 2008 6:46 pm    Post subject: Reply with quote

Lmao, yes there's google in Canada, America, and the UK. Smile

Np, good to hear appreciation.
Back to top
kzone272(not signed in)
Guest





PostPosted: Sun Nov 16, 2008 8:45 pm    Post subject: Reply with quote

would this work (not tried):

Code:
! & m & s:: run http://www.google.com
Back to top
Mikesnm



Joined: 15 Oct 2008
Posts: 25
Location: SoCal

PostPosted: Sun Nov 16, 2008 8:56 pm    Post subject: Reply with quote

I get message: 'invalid hotkey'.
Back to top
View user's profile Send private message
Mikesnm



Joined: 15 Oct 2008
Posts: 25
Location: SoCal

PostPosted: Mon Nov 17, 2008 4:52 am    Post subject: nope Reply with quote

cough.
anyone in socal knows why.

Conquer's code does the trick (even though it sends you to some wierd site up north).

Looks like you guys are thinking there's a really simple way to do it, but seems like those never work- being too logical and all.

Conquer thanks again.
Back to top
View user's profile Send private message
totalmig



Joined: 22 Jul 2008
Posts: 151

PostPosted: Mon Nov 17, 2008 1:02 pm    Post subject: Reply with quote

If your plan was to make a script that only ran something if alt was held down, and then m and s were taped. Then conquers script has a small flaw, if you click alt + i, then do something else, then click alt + m it will launch. Dont know if this is a problem for you with you current hotkeys. If you dont want this you could either set a timedelay on alt + i, so that hotkey1 = false after 5-10 secs. Or could just make it reset if any other buttons were pushed.

Dont know if this matters to you at all Smile
Back to top
View user's profile Send private message
tank



Joined: 21 Dec 2007
Posts: 3700
Location: Louisville KY USA

PostPosted: Mon Nov 17, 2008 6:27 pm    Post subject: Reply with quote

i repeat my suggestion on reading the help file
are you all saying you really cant figure out how to change conquerers url?
just change the url to any site you want
_________________

We are troubled on every side‚ yet not distressed; we are perplexed‚
but not in despair; Persecuted‚ but not forsaken; cast down‚ but not destroyed;
Back to top
View user's profile Send private message
Mikesnm



Joined: 15 Oct 2008
Posts: 25
Location: SoCal

PostPosted: Mon Nov 17, 2008 10:10 pm    Post subject: Reply with quote

We're discussing the hotkey combo, not the URL.
Back to top
View user's profile Send private message
BookwormDragon



Joined: 08 Nov 2008
Posts: 14

PostPosted: Mon Nov 17, 2008 11:17 pm    Post subject: Reply with quote

What about if you've mapped Alt+M to do something already? Can you then map Alt+m+s to do something else, without having the Alt+M action fire as well?
Back to top
View user's profile Send private message
Mikesnm



Joined: 15 Oct 2008
Posts: 25
Location: SoCal

PostPosted: Tue Nov 18, 2008 12:20 am    Post subject: Reply with quote

No. AHK will tell you you've assigned a duplicate key match and will terminate.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group