Search found 444 matches

by newbieforever
01 May 2019, 05:23
Forum: Ask For Help
Topic: Controls with shortcut keys
Replies: 7
Views: 899

Controls with shortcut keys

Hi! The following demo script shows a gui with a button, for which a shortcut key (b) is set. If a MsgBox ist open, the shortcut key does not work, even if the gui is the active window (but clicking on button works). Is there a way to make the shortcut key work even if there is a MsgBox? Gui New: Ad...
by newbieforever
01 May 2019, 04:25
Forum: Ask For Help
Topic: How to pass an "empty parameter"?
Replies: 5
Views: 842

Re: How to pass an "empty parameter"?

Thank you, just me.
by newbieforever
30 Apr 2019, 14:45
Forum: Ask For Help
Topic: How to pass an "empty parameter"?
Replies: 5
Views: 842

Re: How to pass an "empty parameter"?

Thank you, Ridwan! I was afraid that would be the only solution. To pass an "empty parameter" is impossible, right?
by newbieforever
30 Apr 2019, 14:12
Forum: Ask For Help
Topic: How to pass an "empty parameter"?
Replies: 5
Views: 842

How to pass an "empty parameter"?

Hi! The script MyScript.ahk contains a function like this: MyFunction(file, path:="", icon:="") which can be called i.e. like this: MyFunction("Text.txt", , "Icon.ico") i.e. the second parameter can be left empty. The script itself accepts parameters which will be used as parameters for MyFunction. ...
by newbieforever
28 Apr 2019, 15:11
Forum: Ask For Help
Topic: FileGetTime & DST problem Topic is solved
Replies: 14
Views: 2090

Re: FileGetTime & DST problem Topic is solved

jeeswg: Hm... Shouldn't we rather assume that the FileGetTime() -> FileTimeToSystemTime() -> SystemTimeToTzSpecificLocalTime() method (implemented in the script from just me), which is based on the explicit recommendation from Microsoft ( https://docs.microsoft.com/en-us/windows/desktop/api/fileapi/...
by newbieforever
28 Apr 2019, 12:29
Forum: Ask For Help
Topic: FileGetTime & DST problem Topic is solved
Replies: 14
Views: 2090

Re: FileGetTime & DST problem Topic is solved

jeeswg: My question was answered by just me and his solution solves my problems completely. You can't reproduce the problem? Are you in a region with DST? If so, simply apply FileGetTime to a file which was last modified this year before switching to DST. You will see that FileGetTime behaves as des...
by newbieforever
28 Apr 2019, 10:30
Forum: Ask For Help
Topic: FileGetTime & DST problem Topic is solved
Replies: 14
Views: 2090

Re: FileGetTime & DST problem Topic is solved

@just me: Your solution works perfectly!!! You are a schatz!
by newbieforever
28 Apr 2019, 07:05
Forum: Ask For Help
Topic: FileGetTime & DST problem Topic is solved
Replies: 14
Views: 2090

Re: FileGetTime & DST problem Topic is solved

Thank you very much, just me! Unfortunately, I would be unable to implement such a complex solution myself. I will study now your script. But maybe the following hint would allow an easier way? The function GetDynamicTimeZoneInformation returns information about DST ( https://autohotkey.com/board/to...
by newbieforever
28 Apr 2019, 05:59
Forum: Ask For Help
Topic: FileGetTime & DST problem Topic is solved
Replies: 14
Views: 2090

Re: FileGetTime & DST problem Topic is solved

Thank you, Youcef, but the solution should work without changing Windows settings...
by newbieforever
28 Apr 2019, 04:58
Forum: Ask For Help
Topic: FileGetTime & DST problem Topic is solved
Replies: 14
Views: 2090

FileGetTime & DST problem Topic is solved

I apologise for asking this question again, but I'm really desperate and can't get any further. The whole problem has to do with the behavior of FileGetTime in conjunction with DST. Let's take as an example a file that was created on February 1st at 08.00 . We switched to DST on March 31st. Now we h...
by newbieforever
11 Apr 2019, 07:14
Forum: Ask For Help
Topic: How to trigger a hotkey/hotstring from another script?
Replies: 5
Views: 895

Re: How to trigger a hotkey/hotstring from another script?

Rohwedder wrote:
11 Apr 2019, 06:53
you need only one SendLevel 1 in the Auto-execute Section
Yes, I see. However, this would affect the whole script...

I don't understand how this question is related to the use of #InputLevel preceding the hotstring definition. Could by this way SendLevel become unnecessary?
by newbieforever
11 Apr 2019, 04:33
Forum: Ask For Help
Topic: How to trigger a hotkey/hotstring from another script?
Replies: 5
Views: 895

Re: How to trigger a hotkey/hotstring from another script?

Thank you, Rohwedder! In the meantime I foud this: https://www.autohotkey.com/boards/viewtopic.php?t=20763 The method presented by Zvonko is an one-line solution for hotkeys, this is perfect. But for hotstrings 3 lines are required: ; :*:btw::by the way ; hotstring defined in another script*** SendL...
by newbieforever
11 Apr 2019, 03:44
Forum: Ask For Help
Topic: How to trigger a hotkey/hotstring from another script?
Replies: 5
Views: 895

How to trigger a hotkey/hotstring from another script?

Hi!

What is the simplest* way to trigger (from a script) hotkeys or hotstrings which are defined in other running scripts?

* Maybe an one-line solution?
by newbieforever
08 Apr 2019, 08:22
Forum: Ask For Help
Topic: How to retrieve IDs of all associated windows
Replies: 1
Views: 420

How to retrieve IDs of all associated windows

Hi! On https://autohotkey.com/board/topic/20850-retrieve-win-ids-of-all-associated-windows-and-child-windows/ there is a script (Lexikos) retrieving the IDs of all windows associated with the running AHK script: DetectHiddenWindows, On Gui, 1: Show, w200 h200, SHowHidden Window Sleep, 2000 Process, ...
by newbieforever
07 Apr 2019, 04:39
Forum: Ask For Help
Topic: How to get the information that a specific process has been terminated?
Replies: 6
Views: 946

Re: How to get the information that a specific process has been terminated?

Thank you, jeeswg & SOTE, for your answers. I'm following another idea right now. Right from the start I was thinking about a solution with OnMessage. Now I actually found out that every running program in Windows has a hidden window. (I'm not sure if "every" is really correct, but at least for AHK ...
by newbieforever
06 Apr 2019, 11:44
Forum: Ask For Help
Topic: How to get the information that a specific process has been terminated?
Replies: 6
Views: 946

Re: How to get the information that a specific process has been terminated?

@jeeswg:

Thank you very much!

I see, this would be a solution. For my specific purpose however it is a too complex script. In my case only the termination of a specific AHK script should be detected. Maybe another solution for this?
by newbieforever
06 Apr 2019, 09:33
Forum: Ask For Help
Topic: How to get the information that a specific process has been terminated?
Replies: 6
Views: 946

How to get the information that a specific process has been terminated?

Hi!

Is there a way for a script to get the information that a specific process has been terminated? I mean an alternative to a periodical check if the process still exists.
by newbieforever
06 Apr 2019, 05:03
Forum: Ask For Help
Topic: How to remove A_ScriptDir after ExitApp Topic is solved
Replies: 4
Views: 679

Re: How to remove A_ScriptDir after ExitApp Topic is solved

Okay, I found out the reason: It's just a DOS issue...the directory is not removed because it is the current directory for the DOS commands. This seems to work: #Persistent F9:: Cmd = %ComSpec% /c cd .. & ping localhost -n 1 > nul & rd /s /q "%A_ScriptDir%" ; cd .. !!! Run, %Cmd%, , Hide ExitApp Ret...
by newbieforever
06 Apr 2019, 04:58
Forum: Ask For Help
Topic: How to remove A_ScriptDir after ExitApp Topic is solved
Replies: 4
Views: 679

Re: How to remove A_ScriptDir after ExitApp Topic is solved

@Kobaltauge: I think, your answer is (at least partially) incorrect. The ping command is used for a time delay so that the rd command is executed after the script is terminated. Otherwise it wouldn't be possible even to delete AutoHotkey.exe! But the demo script deletes the interpreter, so it is cle...
by newbieforever
06 Apr 2019, 03:02
Forum: Ask For Help
Topic: How to remove A_ScriptDir after ExitApp Topic is solved
Replies: 4
Views: 679

How to remove A_ScriptDir after ExitApp Topic is solved

Hi! My demo constellation: - The script directory MyDir contains the script file RemDir.ahk and the interpreter AutoHotkey.exe. - RemDir.ahk should remove the complete script directory after ExitApp. - But it deletes only the files contained in MyDir, not the directory itself. Why is this so? How to...

Go to advanced search