I don't know what mess you're having in your folder meanwhile, but the best way to solve such problems is cleaning up and doing a fresh installation.

First, de-install everything, and physically erase any rests possibly remaining in your Gamestudio folder. Make sure that you have administrator rights on your PC; the above error messages suggest that parts of your Gamestudio folder are write protected or you are otherwise not allowed to modify them.

Then install the 6.31 trial version from our download page, and unlock it with your key disk.

Finally you may install the 6.40 update.