;Autor: ts-soft EnableExplicit Define EventID Procedure DisableProcessWindowsGhosting() Protected DLL = OpenLibrary(#PB_Any, "user32.dll") If DLL CallFunction(DLL, "DisableProcessWindowsGhosting") CloseLibrary(DLL) EndIf EndProcedure If OpenWindow(0,0,0,500,400,"Window",#PB_Window_SystemMenu|#PB_Window_ScreenCentered|#PB_Window_MinimizeGadget|#PB_Window_SizeGadget|#PB_Window_MaximizeGadget) ButtonGadget(1,100,100,300,200,"Button",0) DisableProcessWindowsGhosting() Repeat EventID=WaitWindowEvent() If EventID=#PB_Event_Gadget Select EventGadget() Case 1 Delay(10000);Ist nur dazu dar, um zu zeigen, dass das Fenster bei einer Auslastung nicht weiß oder grau wird. EndSelect EndIf If EventID = #PB_Event_CloseWindow End EndIf ForEver EndIf