Add escape key function

Press escape key to close out error code and stop code forms