If OpenWindow(0,0,0,500,250,"Window",#PB_Window_SystemMenu|#PB_Window_ScreenCentered) Repeat EventID=WaitWindowEvent() If GetAsyncKeyState_(#VK_A) MessageRequester("","Taste wurde gedrückt",0) EndIf Until EventID = #PB_Event_CloseWindow EndIf