I've got a folder full of ahk scripts. Each script will download one comic based on comic name/url and date.
The user picks the comic from dropdown and date. It then is supposed to run the selected .ahk file and exit.
unfortunately I'm missing something obvious here an I think it's not passing the filename to run?
can someone help please?
Code: Select all
#NoEnv
Folder := A_ScriptDir . "\array"
Gui, Add, DropDownList, x76 y1 w300 vPFL,
Gui, Show, x131 y91 h377 w477, Doug's Script
GoSub, DDL
gui, add, DateTime, vmydate altsubmit
Gui, add, Button, gGo ym, Go
Gui, Show
return
Go:
Gui, Submit
Year := SubStr(mydate,1,4)
Month := SubStr(mydate,5,2)
Day := SubStr(mydate,7,2)
SetWorkingDir, %A_Desktop%\comics
Return
DDL:
Loop, %Folder%\*.ahk
{
GuiControl, , PFL, %A_LoopFileName% ; this will [color=#008000]add[/color] an entry to the DDL control
}
Return
GuiClose:
ExitApp