total = 100 ;Number of loop iterations. Gui, Add, Text,, ETA: Gui, Add, Text, vETA ym, 0:00:00 Gui, Add, Progress, xm w500 h50 cGreen vProgress Range1-%total% Gui, Show StartTime := A_TickCount Loop, %total% { Sleep, 200 ;Replace the sleep with commands to execute. GuiControl,,Progress, %A_Index% time := A_TickCount - StartTime SumX += A_Index SumY += time SumXY += A_Index * time SumX2 += A_Index**2 m := (A_Index * SumXY - SumX * SumY) / (A_Index * SumX2 - SumX**2) b := (SumY - m * SumX) / A_Index ETA := (m * total + b) - (m * A_Index + b) T := A_Year T += ETA/1000, Seconds FormatTime, ETA, %T%, H:mm:ss GuiControl,,ETA, %ETA% } GuiClose: ExitApp