Cancel button update

Program updated so cancel button works