Then try this: #include <GDIPlus.au3> _GDIPlus_Startup() Global $handle = WinGetHandle("[CLASS:Notepad]") Global $hBitmap = Capture_Window($handle, _WinAPI_GetWindowWidth($handle), _WinAPI_GetWindowHeight($handle)) _GDIPlus_ImageSaveToFile($hBitmap, @ScriptDir & "\test.jpg") _GDIPlus_Shutdown() ShellExecute(@ScriptDir & "\test.jpg") Func Capture_Window($hWnd, $w, $h) If Not IsHWnd($hWnd) Then Return SetError(1, 0, 0) If Int($w) < 1 Then Return SetError(2, 0, 0) If Int($