you *could* do something like this:
Global mainWin:TGadget = CreateWindow("Main", 100,100,400,400) Global canvas:TGadget = CreateCanvas(0,0,400,475,mainWin) Global quit:Int = False ActivateGadget(canvas) Global KeyArray:Int[255] While Not quit PollEvent() Select EventID() Case EVENT_KEYDOWN KeyArray(EventData()) = 1 Case Event_KEYUP KeyArray(EventData()) = 0 Case EVENT_WINDOWCLOSE Quit = True End Select If KeyArray(65) Then 'PRESS A TO TEST IT SetGadgetText(mainWin, "Keydown") Else SetGadgetText(mainWin, "Not down") EndIf Wend End