The code that I posted in its existing form is not suitable for interrupt use. It was posted to get you started. Consult the "ON INTERRUPT" statement in the PBP manual to see how you could modify for that purpose.

Changing the polarity of that statement would only be valid if the button pulled up to +Ve and the pin normally idled high.