Change object color

You may like to use the standard button object to make your life easier?

local function myButtonPress( event )     if event.phase == "ended" then         event.target:setFillColor(1,0,0 ) -- FYI, event.target is a reference to myButton     end end local myButton = widget.newButton({     width = 240,     height = 20,     defaultFile = "btnGreen.png",     label = "info",     onEvent = myButtonPress })