Search found 336 matches

by Odlanir
25 Apr 2019, 06:34
Forum: Ask For Help
Topic: A problem about conbine two dictionarys Topic is solved
Replies: 2
Views: 101

Re: A problem about conbine two dictionarys Topic is solved

Code: Select all

MsgBox % key "=" address[key] "=" value
by Odlanir
23 Apr 2019, 11:43
Forum: Ask For Help
Topic: Storing String for Array in a .ini file Topic is solved
Replies: 5
Views: 196

Re: Storing String for Array in a .ini file Topic is solved

Code: Select all

newVar .= (newvar ? "|" : "") element
by Odlanir
21 Apr 2019, 13:04
Forum: Ask For Help
Topic: GUI: Right-click button to display Tooltip?
Replies: 8
Views: 255

Re: GUI: Right-click button to display Tooltip?

OnMessage(0x204, "WM_RBUTTONDOWN") gui,add, button, w100,Button1 gui,add, button, wp,Button2 gui,show return WM_RBUTTONDOWN() { If (A_Gui) { MouseGetPos, , , , control if control ~= "Button" tooltip, % "Right click on " control else tooltip } } esc:: ExitApp return
by Odlanir
21 Apr 2019, 07:52
Forum: Ask For Help
Topic: FileExist() in sub folders
Replies: 2
Views: 114

Re: FileExist() in sub folders

Try this

Code: Select all

filetoSearch := "Dezip.ahk", RootFolder := a_scriptdir
Loop, Files, % RootFolder "\*.*", DR
{
    if ( FileExist(A_LoopFileFullPath "\" filetoSearch) ) {
        filesFound .= "Found in : " A_LoopFileFullPath "`n"
    }
}
MsgBox % filesFound
by Odlanir
21 Apr 2019, 06:48
Forum: Ask For Help
Topic: how to create script for this excel sheets using autohotkey Topic is solved
Replies: 2
Views: 103

Re: how to create script for this excel sheets using autohotkey Topic is solved

This works only if the excel workbook it's exactly as the one you posted. Could be a starting point. excelname := A_ScriptDir "\Prova99.xls" ; put here the name of your excel file XL := ComObjCreate("Excel.Application") xl.workbooks.open(ExcelName) XL.Visible := True ;~ XL.DisplayAlerts := false loo...
by Odlanir
21 Apr 2019, 05:42
Forum: Ask For Help
Topic: Get the name of a screen Topic is solved
Replies: 8
Views: 434

Re: Get the name of a screen Topic is solved

"So the question is now, is it possible to know what the active screen was just before the wxtoimg-script is started?" Anybody who has suggestions how to do this? Put this at the beginning of your script. This gives you some information on the active process before the script start. WinGet, ID, ID,...
by Odlanir
20 Apr 2019, 11:03
Forum: Ask For Help
Topic: Windows 7 to Windows 10: Having to Reload Script
Replies: 15
Views: 662

Re: Windows 7 to Windows 10: Having to Reload Script

You can put this at the end of your script

Code: Select all

min := 30*60
SetTimer, ReloadMe, 1000
return

ReloadMe:
    if (++cnt > Min)
        Reload
return
by Odlanir
19 Apr 2019, 09:15
Forum: Ask For Help
Topic: Handling a solitary linefeed (`n) in the Edit control
Replies: 2
Views: 123

Re: Handling a solitary linefeed (`n) in the Edit control

Code: Select all

str :="a `nb`r`nCd"
MsgBox % RegExReplace(str, "`n")
by Odlanir
19 Apr 2019, 09:03
Forum: Ask For Help
Topic: Highlight a Folder (by Name or Path) in the active Windows 10 Explorer window Topic is solved
Replies: 8
Views: 292

Re: Highlight a Folder (by Name or Path) in the active Windows 10 Explorer window Topic is solved

In the link posted by jeeswg you can find the Function which set the focus in the current Explorer window. Usage: press q to hilight the requested file or folder. press esc to exit. ;~ From : ;~ https://www.autohotkey.com/boards/viewtopic.php?f=6&t=35041 #SingleInstance, force #Persistent ~q:: JEE_E...
by Odlanir
18 Apr 2019, 08:09
Forum: Ask For Help
Topic: random number generator on mouse+refresh with click
Replies: 2
Views: 103

Re: random number generator on mouse+refresh with click

Code: Select all

#SingleInstance, force
#Persistent
CoordMode, ToolTip, Screen

Random, rnd, 1, 100
SetTimer, Go, 10
return

~LButton::
    Random, rnd, 1, 100
return

Go:
    MouseGetPos, xpos, ypos 
    tooltip , %rnd%, %xpos%, %ypos% 
return

esc::
    ExitApp
by Odlanir
18 Apr 2019, 03:03
Forum: Ask For Help
Topic: Counting how many times item is in string Topic is solved
Replies: 9
Views: 271

Re: Counting how many times item is in string Topic is solved

Code: Select all

myvar := "2122,3285,6525,2122,5485,6525"
myColl := ComObjCreate("Scripting.Dictionary")
For Each, x In StrSplit(myVar, ",")
    myColl.Exists(x) ? myColl.Item(x) ++ : myColl.Item(x) := 1
For x In myColl
	myResult .=  myColl.Item(x) "`t" x "`n"
Sort, myResult, RN
MsgBox % myResult
by Odlanir
14 Apr 2019, 04:40
Forum: Ask For Help
Topic: ActiveCell.value+1 not worked if cell is date.
Replies: 3
Views: 198

Re: ActiveCell.value+1 not worked if cell is date.

This works for me:

Code: Select all

oExcel.ActiveCell.NumberFormat := "########"
oExcel.ActiveCell.value := oExcel.ActiveCell.value + 1
oExcel.ActiveCell.NumberFormat := "gg/MM/aaaa"  ; European date
;~ or
;~ oExcel.ActiveCell.NumberFormat := "MM/dd/yyyy" ; USA date ( I think )
by Odlanir
08 Apr 2019, 07:12
Forum: Ask For Help
Topic: How to chang the SplashText's text Topic is solved
Replies: 9
Views: 445

Re: How to chang the SplashText's text Topic is solved

Code: Select all

SplashTextOn, , , % Clipboard
SetTimer, RefreshSplash, 500 ; 500 is arbirary, choose the delay you prefer
return

RefreshSplash:
    SplashTextOn, , , % Clipboard
return
by Odlanir
08 Apr 2019, 04:07
Forum: Ask For Help
Topic: Size of array after stringsplit Topic is solved
Replies: 6
Views: 345

Re: Size of array after stringsplit Topic is solved

Code: Select all

myArray := StrSplit(Text, "`n","`r")
by Odlanir
07 Apr 2019, 04:38
Forum: Ask For Help
Topic: showing a ToolTip when Mouse cursor over on items of ListView Topic is solved
Replies: 14
Views: 639

Re: Help with showing a ToolTip when Mouse cursor over on item Topic is solved

I think you must select an Item to get the text: WM_MOUSEMOVE(wParam, lParam, Msg) { ControlGetText, TXT_1, Button1 ControlGetText, TXT_2, Button2 ControlGetText, TXT_3, Button3 ControlGet, OutputVar, List, Focused, SysListView321 MouseGetPos,,,,ctrl If SubStr(ctrl,1,6) = "Button" { b := SubStr(ctrl...
by Odlanir
05 Apr 2019, 04:28
Forum: Ask For Help
Topic: Get FilePath of A Running Script
Replies: 4
Views: 177

Re: Get FilePath of A Running Script

Why not:

Code: Select all

...
if queryEnum[process] {
    MsgBox 0, Command line, % StrSplit(process.CommandLine, """")[4]
...
by Odlanir
01 Apr 2019, 08:27
Forum: Ask For Help
Topic: Help to replace "." (dots) with " " (space) in a string Topic is solved
Replies: 6
Views: 331

Re: Help to replace "." (dots) with " " (space) in a string Topic is solved

@ swagfag You're right!. It should be:

Code: Select all

str := RegExReplace(str, "(\d+\.\d+)\.?|(\.)", "$1 ")
by Odlanir
01 Apr 2019, 07:59
Forum: Ask For Help
Topic: Help to replace "." (dots) with " " (space) in a string Topic is solved
Replies: 6
Views: 331

Re: Help to replace "." (dots) with " " (space) in a string Topic is solved

Or:

Code: Select all

str := "Wempen,.Faithe.-.No.018.15.-.Office.-.2016.For.Seniors.For.Dummies"
str := RegExReplace(str, "(\d+\.\d+)|(\.)", "$1 ")
MsgBox % str
by Odlanir
28 Mar 2019, 06:50
Forum: Ask For Help
Topic: Paste variables in a repeated cell pattern in Excel Topic is solved
Replies: 11
Views: 400

Re: Paste variables in a repeated cell pattern in Excel Topic is solved

Some like this?

Code: Select all

Var:=1
Xl := ComObjActive("Excel.Application")
Xl.Range(xl.cells(1,1),xl.cells(5,5)).Value := Var

Go to advanced search