Search found 493 matches

by newbieforever
07 May 2018, 01:33
Forum: Ask for Help (v1)
Topic: Hotstring function with function as replacement Topic is solved
Replies: 6
Views: 1361

Re: Hotstring function with function as replacement Topic is solved

@swagfag: ABSOLUTELY GREAT, thank you very much!!! PS: Just an incompetent question from an ahk newbie: If the hotstrings function was implemented with the explicite option that the replacement can be a function, why this wasn't done in such a way that Hotstring(HStr, "Insert(String)") would be poss...
by newbieforever
06 May 2018, 14:01
Forum: Ask for Help (v1)
Topic: Hotstring function with function as replacement Topic is solved
Replies: 6
Views: 1361

Hotstring function with function as replacement Topic is solved

Hi! I am unable to figure out how this should be done... This is just a demo script. Both HStr and String are read from a file. The replacement in the Hotstrings function should be a function. HStr := ":X*:btw" String := "By the way" Hotstring(HStr, "Insert(String)") ; How to do this correctly??? RE...
by newbieforever
05 Apr 2018, 14:18
Forum: Ask for Help (v1)
Topic: A new file timestamp problem (DST & FAT32)
Replies: 2
Views: 530

Re: A new file timestamp problem (DST & FAT32)

@jeeswg: I think, I will give up! It's simply too stupid... (SW developer are forced to do things like this: "Files modified on FAT volumes will not be uploaded to the server when the size didn't change and when the modification time was changed by just 1 hour +/- 2 secs" / https://github.com/ownclo...
by newbieforever
05 Apr 2018, 07:12
Forum: Ask for Help (v1)
Topic: A new file timestamp problem (DST & FAT32)
Replies: 2
Views: 530

A new file timestamp problem (DST & FAT32)

Hi! My file backup script compares the modification time of files on the source drive and on the backup drive to backup files with different modification time. Some time ago I discovered a problem associated with FAT-formated drives. FAT has a 2 sec timestamp granularity! So I adapted my script to i...
by newbieforever
10 Mar 2018, 03:50
Forum: Ask for Help (v1)
Topic: How to know that the last DOS command is executed?
Replies: 6
Views: 1022

Re: How to know that the last DOS command is executed?

@jeeswg, Odlanir: Thank you! Yes, the solution with Process would be nicer, but: My loop copies a number of files, and the actual copying of the last file may be finished several seconds after the loop is processed. But Process, Exist, vPID reports the end of the last process much sooner! (There see...
by newbieforever
07 Mar 2018, 13:36
Forum: Ask for Help (v1)
Topic: How to know that the last DOS command is executed?
Replies: 6
Views: 1022

Re: How to know that the last DOS command is executed?

@Odlanir:

Thank you.

Yes, a timer was my idea to. Another solution seems not to exist...
by newbieforever
07 Mar 2018, 08:19
Forum: Ask for Help (v1)
Topic: How to know that the last DOS command is executed?
Replies: 6
Views: 1022

How to know that the last DOS command is executed?

Hi! In a loop I use xcopy (with Run) to copy files from one drive to another: Run % comspec " /c xcopy """ FileS """ """ FileT """ /h/i/c/k/e/r/y", , Hide (To use xcopy and to use Run instead of RunWait is necessary for my specific script.) How could I register when the last Run command is executed,...
by newbieforever
27 Feb 2018, 03:42
Forum: Ask for Help (v1)
Topic: DropDownList, how to update on click?
Replies: 1
Views: 346

DropDownList, how to update on click?

Hi! My next newbie problem: Gui Start: Add, DropDownList, vvDrives ggDrives, %DrivesList% The DropDownList contains the list of the available drives (DriveList is e.g. 'C|D|G') and is created on the start of the script. How I could force an update of the DriveList on every click on the DropDownList ...
by newbieforever
25 Feb 2018, 05:26
Forum: Ask for Help (v1)
Topic: Replacing any substring between two characters Topic is solved
Replies: 5
Views: 1414

Replacing any substring between two characters Topic is solved

Hi! RegExReplace is not easy to understand for a newbie... String := "abc C:\Dir1\cdfgh hij D:\Dir2\jklmn nopq" Repla := "X:\Dirr\" ;;; ;;; Result: String := "abc X:\Dirr\cdfgh hij X:\Dirr\jklmn nopq" How to replace all substrings beginning with the character preceeding :\ and ending with the first ...
by newbieforever
02 Dec 2017, 16:29
Forum: Ask for Help (v1)
Topic: Strange: Incorrect modification time (seconds) of a copyed file Topic is solved
Replies: 4
Views: 1321

Re: Strange: Incorrect modification time (seconds) of a copyed file Topic is solved

@jeesweg:
I THANK YOU SO MUCH!!!

FAT has a 2 sec timestamp granularity!

Now I am able to solve my problem: When comparing two timestamps, instead of If (TS1 = TS2) I use now If (Abs(TS1 - TS2) < 3) to identify that the files have the same modification date.
by newbieforever
02 Dec 2017, 14:18
Forum: Ask for Help (v1)
Topic: Strange: Incorrect modification time (seconds) of a copyed file Topic is solved
Replies: 4
Views: 1321

Strange: Incorrect modification time (seconds) of a copyed file Topic is solved

Is this a known issue? When a file is copyed to another drive, the modification time is changed slightly (1 or 2 seconds). I can reproduce this with the following demo script. Drive D in my case is a USB stick. FileAppend, , C:\Test\TestFile FileCopy, C:\Test\TestFile, D:\Test\TestFileX, 1 FileGetTi...
by newbieforever
20 Oct 2017, 04:55
Forum: Ask for Help (v1)
Topic: Annoying error message... Topic is solved
Replies: 2
Views: 633

Re: Annoying error message... Topic is solved

Thank you very much, Helgef. I think Try solves my problem.
by newbieforever
19 Oct 2017, 15:15
Forum: Ask for Help (v1)
Topic: Annoying error message... Topic is solved
Replies: 2
Views: 633

Annoying error message... Topic is solved

From a (compiled) script with this: If !WinActive("ahk_id " . WinId) Return Gui Agui: +Parent%WinId% sometimes comes the error message: Invalid or nonexistent owner or parent window or Could not create window obviously in a time situation where the WinId window was closed by the user during the exec...
by newbieforever
15 Oct 2017, 08:22
Forum: Ask for Help (v1)
Topic: Mouse wheel granularity
Replies: 6
Views: 1523

Re: Mouse wheel granularity

@just me:

Thank you very much, just me, for your explanations!
Theoretically, is there another method to force scroll in application's windows? (My Writer windows have no controls at all...)
by newbieforever
15 Oct 2017, 02:25
Forum: Ask for Help (v1)
Topic: Mouse wheel granularity
Replies: 6
Views: 1523

Re: Mouse wheel granularity

OK, what about a 'simplest' question to 'SendMessage, 0x20A': ;MouseGetPos, x, y ;SendMessage, 0x20A, 120 << 16, (y << 16) | x,, A SendMessage, 0x20A, 120 << 16, (0 << 16) | 0,, A Mouse coordinates seams to be unnecessary, the command works exactly in the same way in my Writer window. Why? (Or: Why ...
by newbieforever
14 Oct 2017, 17:40
Forum: Ask for Help (v1)
Topic: Mouse wheel granularity
Replies: 6
Views: 1523

Re: Mouse wheel granularity

OK, how about a 'modester' question: MouseGetPos, x, y SendMessage, 0x20A, 120 << 16, (y << 16) | x,, A I found out that, if the mouse wheel is set in Windows to 1 line per notch (Mouse Properties > Wheel), the above command scrolls one line (in my Writer window). With a delta of e.g. 40 instead of ...
by newbieforever
13 Oct 2017, 05:29
Forum: Ask for Help (v1)
Topic: Mouse wheel granularity
Replies: 6
Views: 1523

Re: Mouse wheel granularity

@just me:

Yes, you are right!!! With 120 << 16 the command scrolls by 1 line, as would be expected.

However, a delta below 120 doesn't change the scroll effect...
by newbieforever
13 Oct 2017, 04:40
Forum: Ask for Help (v1)
Topic: Mouse wheel granularity
Replies: 6
Views: 1523

Mouse wheel granularity

In my script I am using hotkeys to do vertical scrolling in a text editor. The scroll commands operate with SendMessage. This method is the best I could find. A demo: CoordMode, Mouse, Client RETURN F9:: MouseGetPos, x, y SendMessage, 0x20A, 120 << 17, (y << 16) | x,, A Return F10:: MouseGetPos, x, ...

Go to advanced search