Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #NoEnv
- #SingleInstance, Force
- SetBatchLines, -1
- ini = %A_Scriptdir%\RUNNER.ini ; Replace with your INI path
- spath := {}
- Gui, New
- ;Gui, Color, 884488
- Gui New, +Hwndmygui
- WinSet, TransColor, EEAA99
- Gui, +ToolWindow -Border
- Gui,Font,S14 Bold,Calibri
- Loop {
- IniRead, sname, %ini%, Shortcuts, ShortcutName%A_Index%
- If (sname = "ERROR")
- Break
- IniRead, thisPath, %ini%, Shortcuts, ShortcutPath%A_Index%
- If FileExist(thisPath) {
- spath[sname] := thisPath
- Gui, Add, Button, w200 h20 y+m gProg, %sname%
- }
- }
- Gui, Show, X775 Y2 W240 H720, Najeeb Run
- Return
- Prog:
- If FileExist(thisPath := spath[A_GuiControl]) {
- SplitPath, thisPath, fn
- If WinExist("ahk_exe " fn)
- WinActivate
- Else Run, %thisPath%
- } Else MsgBox, 48, File not found, %thisPath%
- Return
- F1::
- if (WinExist("ahk_id " mygui))
- Gui %mygui%: Hide
- else
- Gui %mygui%: Show
- Return
- #R::Reload ;<-- ~ Reload Script ~
- #S::Suspend ;<-- ~ Suspend Script ~
- #P::Pause ;<-- ~ Pause Script ~
- #M::WinMinimize, ;<-- ~ Minimize Script ~
- ESC::ExitApp ;<-- ~ Exit Script ~
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement