Search found 326 matches

by Smile_
05 Jan 2021, 11:13
Forum: Ask For Help
Topic: Last Word of a TXT File
Replies: 6
Views: 128

Re: Last Word of a TXT File

Code: Select all

FileRead, Text, tmp.txt  ; Text File Location
Msgbox % Words[(Words := StrSplit(Trim(Text), [" ", "`r", "`n"])).Length()]
by Smile_
04 Jan 2021, 11:51
Forum: Ask For Help
Topic: rename files
Replies: 5
Views: 146

Re: rename files

Loop, Files, C:\Users\Audio1\Dropbox\Audio\PROMOS\*.omf { IfInString, A_LoopFilename, NDP { IfNotInString, FileNames, %A_LoopFilename% { FileCopy, %A_LoopFileFullPath%, C:\Users\Audio1\Dropbox\Audio\PROMOS\5_%A_LoopFilename% filedelete, %A_LoopFileFullPath% } } IfInString, A_LoopFilename, OPEN { If...
by Smile_
01 Jan 2021, 06:35
Forum: Ask For Help
Topic: Underlining text problem Topic is solved
Replies: 6
Views: 161

Re: Underlining text problem Topic is solved

Not so perfect but It might help #SingleInstance, Force DllCall("GDI32.DLL\AddFontResourceEx", Str,"XPtahoma.ttf",UInt,(FR_PRIVATE:=0x10), Int,0) ; loads XpTahoma.ttf SysGet, MainMonitorNumber, MonitorPrimary ; gets primary monitor id SysGet, MainMonitor, Monitor, %MainMonitorNumber% ; gets dimensio...
by Smile_
26 Dec 2020, 09:26
Forum: Ask For Help
Topic: Picking unique items from an array randomly.
Replies: 6
Views: 103

Re: Picking unique items from an array randomly.

I think you meant this, no?, (Picking up 12 different items) items := [1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20] ready := [] loop, 12 { loop ; Remove this loop to allow repeating picked up items. random, n, 1, items.length() ; until !ayes(ready,n) ; ready.push(items[n]) } test := "" loop %...
by Smile_
26 Dec 2020, 08:56
Forum: Ask For Help
Topic: Compare and delete values of an array Topic is solved
Replies: 11
Views: 235

Re: Compare and delete values of an array Topic is solved

@Rohwedder
If you flip uh58404 and 58404 it shows this ak99901 11122

Edit: What I meant is if the longer string is in the second loop InStr(V1,V2) = false
Try with this array

Code: Select all

["99901","ak99901","58404","58404","11122","uh58404"]
by Smile_
26 Dec 2020, 05:43
Forum: Ask For Help
Topic: How to Write Correctly [to] the command window Topic is solved
Replies: 5
Views: 88

Re: How to Write Correctly [to] the command window Topic is solved

It would be easier if you just create a Batch script containing your commands with FileAppend for example and just run it with Run command.
by Smile_
26 Dec 2020, 05:32
Forum: Ask For Help
Topic: Fileinstall not copying files?
Replies: 4
Views: 46

Re: Fileinstall not copying files?

Resource Hacker for example: http://www.angusj.com/resourcehacker/
by Smile_
26 Dec 2020, 05:31
Forum: Ask For Help
Topic: How to Write Correctly [to] the command window Topic is solved
Replies: 5
Views: 88

Re: How to Write Correctly [to] the command window Topic is solved

Code: Select all

Send, % "for %i in (*.webm) do ffmpeg -i ""%i"" ""%~ni.mp3""`n"
by Smile_
26 Dec 2020, 05:22
Forum: Gaming
Topic: How to do it?
Replies: 4
Views: 80

Re: How to do it?

==> Call to nonexistent function.
Exactly as you see it, there is no function named Perform_Action in your code to call, the Try command wont try it until it exists.
by Smile_
26 Dec 2020, 05:16
Forum: Ask For Help
Topic: How to Write Correctly [to] the command window Topic is solved
Replies: 5
Views: 88

Re: How to Write Correctly Topic is solved

Code: Select all

Send, % "for %i in (*.webm) do ffmpeg -i %i %~ni.mp3`n"
;------------------------------------------------------
Send, for `%i in (*.webm) do ffmpeg -i `%i `%~ni.mp3`n
I suggest to use this Send, % "for %i in (*.webm) do ffmpeg -i ""%i"" ""%~ni.mp3""`n", to include spaces inside files names.
by Smile_
26 Dec 2020, 05:11
Forum: Ask For Help
Topic: Fileinstall not copying files?
Replies: 4
Views: 46

Re: Fileinstall not copying files?

FileInstall
Includes the specified file inside the compiled version of the script.
Did you looked inside the compiled AHK executable?
by Smile_
26 Dec 2020, 05:08
Forum: Gaming
Topic: How to do it?
Replies: 4
Views: 80

Re: How to do it?

by Smile_
26 Dec 2020, 03:15
Forum: Ask For Help
Topic: Regex to get all uppercase letters Topic is solved
Replies: 8
Views: 147

Re: Regex to get all uppercase letters Topic is solved

Code: Select all

Msgbox % RegexReplace("&P7gf6f6 USft6D", "\P{Lu}")
[v1.0.90+]: Unicode character properties. Not supported on ANSI builds
by Smile_
25 Dec 2020, 13:41
Forum: Ask For Help
Topic: Regex to get all uppercase letters Topic is solved
Replies: 8
Views: 147

Re: Regex to get all uppercase letters Topic is solved

That is a lot shorter

Code: Select all

Msgbox % RegexReplace("&P7gf6f6 USft6D", "[^A-Z]", "")
by Smile_
25 Dec 2020, 13:31
Forum: Ask For Help
Topic: Regex to get all uppercase letters Topic is solved
Replies: 8
Views: 147

Re: Regex to get all uppercase letters Topic is solved

At the moment this what came to my mind

Code: Select all

str := "&P7gf6f6 USft6D", match := ""
Loop, Parse, % str
{
    If (A_LoopField ~= "[A-Z]")
        match .= A_LoopField
}
Msgbox, % match
ExitApp
by Smile_
24 Dec 2020, 06:38
Forum: Ask For Help
Topic: Restrict loop search subfolder depth Topic is solved
Replies: 2
Views: 48

Re: Restrict loop search subfolder depth Topic is solved

Code: Select all

Loop, Files, % "C:\*", D
{
   ParentFolder := A_LoopFileFullPath
   Loop, Files, % ParentFolder "\*", D
      Msgbox % A_LoopFileFullPath
}
by Smile_
20 Dec 2020, 07:46
Forum: Ask For Help
Topic: read file to match input as you write and show it below Topic is solved
Replies: 11
Views: 156

Re: read file to match input as you write and show it below Topic is solved

^k:: If WinExist("Search in C:\Users\jomaweb\hotkeys.txt") { Gui, Show,, Search in C:\Users\jomaweb\hotkeys.txt Return } Gui, Add, Text,, Entering the String to search Gui, Add, Edit, w350 h20 vText gSearch_Display Gui, Add, Edit, w350 h200 vDisplay +HScroll Gui, Add, Button, xm+305 ym+250 w45, Exi...
by Smile_
16 Dec 2020, 01:34
Forum: Ask For Help
Topic: How to detect window message WM_KILLFOCUS?
Replies: 4
Views: 92

Re: How to detect window message WM_KILLFOCUS?

Tried this?

Code: Select all

OnMessage(0x08, "MyShellMessageFunction")

Go to advanced search