Search found 34 matches

by CodeKiller
19 Aug 2020, 10:39
Forum: Ask For Help
Topic: Disable script for specific window
Replies: 5
Views: 93

Re: Disable script for specific window

yes same hot key does specific function according to current window for instant in some game the ² minimize the window, in some other it send Esc before, etc. I have some keys that also have a "default" behavior for any window then specific window, this is this case that was an issue as it was doing...
by CodeKiller
19 Aug 2020, 07:33
Forum: Ask For Help
Topic: Disable script for specific window
Replies: 5
Views: 93

Re: Disable script for specific window

In fact in some case it can prevent some hotkeys to work. Example: #If !WinActive("ahk_exe Notepad.exe") F2::Msgbox HERE #If WinActive("ahk_exe Mspaint.exe") F2::Msgbox AND THERE This code does not work for the second part, as the first one will always be true and AHK does not test another hotkey if...
by CodeKiller
19 Aug 2020, 06:11
Forum: Ask For Help
Topic: Disable script for specific window
Replies: 5
Views: 93

Re: Disable script for specific window - Answered !

Holy shhhhhh...

So simple I did not think about that (negative test) as almost all my file is full of #If WinActive... :facepalm:

I created a big huge group of "all windows" key (they were scattered all over my script... jesus...) in a #If !WinActive and it works like a charm.

Thanks !
by CodeKiller
19 Aug 2020, 02:51
Forum: Ask For Help
Topic: Disable script for specific window
Replies: 5
Views: 93

Disable script for specific window

Hello, I wonder if there is a way to disable a whole "script" for a specific window. My script is about 1600 lines so obviously I cannot use #If or something like that on each hotkey... If it is not possible I guess it could be a great concept to implement. Like SetTitleMatchMode, #Include, etc. you...
by CodeKiller
13 Sep 2019, 02:47
Forum: Ask For Help
Topic: Variable Multiline text
Replies: 1
Views: 286

Variable Multiline text

Hello all, Yes this is silly subject but I don't understand how you can assign a text to a variable that contains { }. This exemple failles for example : Text = ("{0}" - Value "{1}" Text "{2}" Text ) It gives me error for "{1}" : attribute/field that faild (with a nice type :-)) validation Error: Th...
by CodeKiller
30 Jan 2018, 05:47
Forum: Ask For Help
Topic: Remap the Paragraph Key
Replies: 5
Views: 1674

Re: Remap the Paragraph Key

I don't know if it come from an older version than the latest but now it is simplified :

sc029::Msgbox OK

No longer need "vkbf". :rainbow:

For information :
AHK help, Index, key list
Go at the bottom "Special keys".
by CodeKiller
20 Jan 2018, 11:03
Forum: Ask For Help
Topic: ComObjCreate Internet Explorer
Replies: 1
Views: 586

Re: ComObjCreate Internet Explorer

Ok, after investigation, I manage to get almost what I want (except that getElementById is still not working). WinGetActiveTitle T IE := IEGet(T) IE.navigate("https://www.google.fr") IELoad(IE) Loop % IE.document.images.length Msgbox % IE.document.images[A_index - 1].href This is working fine. Now I...
by CodeKiller
20 Jan 2018, 10:37
Forum: Ask For Help
Topic: ComObjCreate Internet Explorer
Replies: 1
Views: 586

ComObjCreate Internet Explorer

Hi all, I used to use a script to do some search in IE but now the script is no longer working. I create a new one just to be sure, but still does not work with simple things like that : WinGetActiveTitle T IE := IEGet(T) IE.navigate("https://www.google.fr") IELoad(IE) Msgbox % IE.document.location ...
by CodeKiller
06 Apr 2016, 13:54
Forum: Editors
Topic: Setup Notepad++ for AutoHotkey
Replies: 137
Views: 330784

Re: Setup Notepad++ for AutoHotkey

Confirm this works for Windows 10 X 64 to make notpad++ as default editor for AHK files. HKEY_CLASSES_ROOT\AutoHotkeyScript\Shell\Edit\Command "C:\Program Files (x86)\Notepad++\notepad++.exe" "%1" HTH Just to add some info : it works only if you use the installer, if you do not have the defaut regk...
by CodeKiller
26 Feb 2016, 08:42
Forum: Ask For Help
Topic: How can i make a hotkey work different at different areas of same excel sheet? Topic is solved
Replies: 3
Views: 1269

Re: How can i make a hotkey work different at different areas of same excel sheet? Topic is solved

F5:: Msgbox % A_CaretX " - " A_CaretY Return But it's related to a "converted" relative caret position link to the height of a line and the width of the row. Displayed in pixels. If you want exact cell in a format Cells(5,6) for example you can use ComObj*. Generique example to edit the content of ...
by CodeKiller
26 Feb 2016, 07:36
Forum: Ask For Help
Topic: "FileMoveDir" with Admin-Rights
Replies: 4
Views: 1347

Re: "FileMoveDir" with Admin-Rights

Why don't you use Run command ? So that the script will run normaly and only this command

Code: Select all

RunAs Administrator
Run %command%
RunAs
by CodeKiller
26 Feb 2016, 06:47
Forum: Ask For Help
Topic: Classes: additional action when setting a property
Replies: 5
Views: 1635

Re: Classes: additional action when setting a property

Ah yeah sorry I was running the scripts with ahk.exe instead of the ahku64.exe... Thanks !
by CodeKiller
26 Feb 2016, 06:07
Forum: Ask For Help
Topic: Closing PIA
Replies: 7
Views: 2283

Re: Closing PIA

Did you try to send message to the toolbar (tray icon) ? I tried controlclick etc but it just click on the taskbar, not the control itself : F5:: ;WinActivate ahk_class Shell_TrayWnd ; ToolbarWindow321 ; ControlSend ToolbarWindow321, RButton ,ahk_class Shell_TrayWnd ControlClick , , ahk_class Shell_...
by CodeKiller
26 Feb 2016, 04:57
Forum: Ask For Help
Topic: Classes: additional action when setting a property
Replies: 5
Views: 1635

Re: Classes: additional action when setting a property

var { set { Which AHK version is that ??? :shock: If I copy paste this code it just crash at execution... --------------------------- Test.ahk --------------------------- Error at line 6. Line Text: var Error: Expected assignment or class/method definition. The program will exit. -------------------...
by CodeKiller
26 Feb 2016, 04:35
Forum: Ask For Help
Topic: How to allow drag&drop while preventing fast mouse clicking?
Replies: 2
Views: 1018

Re: How to allow drag&drop while preventing fast mouse clicking?

The drag and drop is working fine the Lexikos' script :

Code: Select all

~LButton::return  ; Set A_PriorHotkey.
#If A_PriorHotkey != "" && A_TimeSincePriorHotkey < 200
LButton::return  ; Block hotkey.
by CodeKiller
24 Feb 2016, 08:43
Forum: Ask For Help
Topic: How to make a button switch on and off Topic is solved
Replies: 2
Views: 871

Re: How to make a button switch on and off Topic is solved

You can define "keep mbutton down" ? Do you meant : click click click click... or just click and keep down (one single long click) ? If you want a more understandable script (with shift as an example so you can really see if it is working) : #InstallKeybdHook #SingleInstance Force $Shift:: If Presse...
by CodeKiller
24 Feb 2016, 08:27
Forum: Ask For Help
Topic: Intercept key from screensaver
Replies: 1
Views: 689

Re: Intercept key from screensaver

If I open a scr file and press a hotkey it works (the history of ahk show the name of the screen saver, like Bubble for example). And I cannot change the timer to do a real test here so... But, if the screen saver is secured (require password to leave the screen saver) it's normal AHK doesn't work.....
by CodeKiller
24 Feb 2016, 08:10
Forum: Ask For Help
Topic: Search multiple files and extract text
Replies: 2
Views: 1001

Re: Search multiple files and extract text

For Word document you can try with "comobjcreate" and use inner function to copy the whole content to the clipboard, read it, etc.

To extract text from PDF you can try this tool : http://www.a-pdf.com/text/cmd.htm
It can run in command-line so it will be friend with AHK and the "Run" command.
by CodeKiller
24 Feb 2016, 08:03
Forum: Ask For Help
Topic: Apply AutoHotkey to commands received from virtual keyboards
Replies: 1
Views: 731

Re: Apply AutoHotkey to commands received from virtual keyboards

But that doesn't work with the input I get from the network
This is the main issue I think.

How do you receive the "command" ???

Is it "typed" by a programme (speech recognition) ?

Perhaps I am wrong but I think AHK only recognize "manualy" typed keys.
by CodeKiller
24 Feb 2016, 07:43
Forum: Ask For Help
Topic: Closing PIA
Replies: 7
Views: 2283

Re: Closing PIA

Don't even understand what you want to do...
If it's a programme yo uwant to close :

Process Close, notepad.exe

Or in a more brutal way : taskkill /F /IM notepad.exe

For example...

Can you explain more ?

Go to advanced search