Not a solution to the "subscript" error... But couldn't the "goto check_done", in line 320, be replaced with an "exit for"?... and similar for line 300?
Even though, for me anyway, the demo runs 'very' quickly, I am impressed that the images are actually 'drawn" and not sprites. So cool...