Code to restore minimized window (translated from "codigo para restaurar ventana minimizada")

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
spopow1ch
Posts: 1
Joined: 25 Mar 2024, 12:43

Code to restore minimized window (translated from "codigo para restaurar ventana minimizada")

25 Mar 2024, 12:50

Moderator edit: Translation provided for body and subject (please only post in English in the main part of the forum!)
Google Translate wrote:Hello, how would a code be to restore the last window that was minimized to the taskbar? That is, any program that minimizes the last one, only restores that last one and not all the others, I was investigating and I couldn't find the solution. Thanks in advance.

PS: I'm new to this and this is the version I have AutoHotkey_1.1.36.02
hola buenas como seria un codigo para restaurar la ultima ventana que fue minimiado en la barra de tareas? es decir cualquier programa que minimize el ultimo, solo restaurar esa ultima y no todas las demas, es que estuve indagando y no encontre la solucion. Gracias de antemano.

pd: soy nuevo en esto y esta es la version que tengo AutoHotkey_1.1.36.02
GEV
Posts: 1005
Joined: 25 Feb 2014, 00:50

Re: Code to restore minimized window (translated from "codigo para restaurar ventana minimizada")

25 Mar 2024, 16:37

Code: Select all

; Press F1 to restore the last minimized window:

F1::
	arr := []
	WinGet, id, list,,, Program Manager
	Loop, %id%
	{
		this_id := id%A_Index%
		WinGet, state, MinMax, ahk_id %this_id%
		if (state = -1)
			arr.push(this_id)
	}
	last := arr.pop()
	WinRestore, % "ahk_id " last
return

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: balawi28, bobstoner289, ntepa and 184 guests