Quickstarter Close Windows API Windows Didier Dorange-Pattoret Is there another way to terminate the OOo process even if the QS is running beside Declare Function GetActiveWindow Lib "user32" () As Long Declare Sub ExitProcess Lib "kernel32" (ByVal uExitCode As Long) Sub Essai rem getting the active window's handle. hWnd = GetActiveWindow() rem closing all active windows On error resume Next myEnum = StarDesktop.Components.CreateEnumeration Do while myEnum.HasmoreElements oDoc = myEnum.NextElement If HasUnoInterfaces(oDoc, "{@see com.sun.star.util.XCloseable}") Then oDoc.close(true) Else oDoc.dispose() End If Loop On error goto 0 rem closing the quickstarter ExitProcess(hWnd) End Sub