Jump to content


These hotkeys stopped working, without syntax complaint


  • Please log in to reply
4 replies to this topic

#1 AntonO

AntonO
  • Guests

Posted 22 April 2012 - 12:32 PM

This script should, and before did, jump in text with caps+a,s,d,f.
However, with some latest updates it does not anymore. What is wrong??



Furthermore, presing caps+q should then take a character and send a corresponding sigs, etc.
Getting that to work would be awesome.

Thanks!


#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn  ; Recommended for catching common errors.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.

capslock & a::
Send {Home}
return
capslock & s::
Send {^leftarrow}
return
capslock & d::
Send {^rightarrow}
return

; add text here
capslock & q::
	Input, OutputVar, L1
	tooltip, %outputvar%


	if (OutputVar = "p")
		send 900810****
	if (OutputVar = "p")
		send anton.****@gmail.com
	if OutputVar = "a"
		send Anton ***
return


;testing tooltips, favourite documents etc
^r:: tooltip, hej

capslock & f::Send {end}

capslock & 2:: run D:\
capslock & 1:: run C:\Users\Anton\Desktop\Dropbox
capslock & 3::
 run C:\Program Files
 run C:\Program Files (x86)
return

capslock & 4:: run D:\Downloads




#2 a_h_k

a_h_k
  • Members
  • 681 posts

Posted 22 April 2012 - 01:45 PM

Did u check what u had chnged?

For starters...
Send {^leftarrow} ---> should be [color=#BF0000]Send ^{Left}[/color]
Send {^rightarrow} ---> should be [color=#BF0000]Send ^{Right}[/color]


#3 AntonO

AntonO
  • Guests

Posted 23 April 2012 - 07:13 PM

Thanks, your input helped me newbie alot! :O

But I figured the main issue was that notepad++ ran another AHK script than mine when I clicked F5!

Want a better editor...

#4 a_h_k

a_h_k
  • Members
  • 681 posts

Posted 24 April 2012 - 12:56 PM

Yeah, i don't use notepad++ to run anything .. but otherwise i find its a great editor (i created my own AutoHotkey file for syntax-highlighting, have a custom color scheme, & use my own custom "fold" meta-statements) :)

#5 CodeKiller

CodeKiller
  • Members
  • 2066 posts

Posted 24 April 2012 - 01:42 PM

Thanks, your input helped me newbie alot! :O

But I figured the main issue was that notepad++ ran another AHK script than mine when I clicked F5!

Want a better editor...

The "Run" command of NP++ doesn't use the file you are editing...
It just allow the user to run an external program.
But you can make it run you program that way:
Open (in notepad or anything else but NOT notepad++) the file shortcuts.xml which is in the folder of NP++ (or the one in AppData etc., don't know, as I run a USB install of NP++).
In this file you can find that :
<NotepadPlus>
    <InternalCommands />
    <Macros />
    <UserDefinedCommands>
        <Command name="AHK" Ctrl="yes" Alt="no" Shift="yes" Key="68">H:\User\AHK\AutoHotkey.exe [color=#FF0000]"H:\Desktop\WScan.ahk"[/color]</Command>
    </UserDefinedCommands>
    <PluginCommands />
    <ScintillaKeys />
</NotepadPlus>
If you want to make it run your script change the thing in red.
But it's a "fixed" command, so add as many entry as you want.