I think that this ticket may be two-fold, as it is indicative of two separate issues.
Running the latest Keepass 1 available for the moment, 1.25, on Windows 8 (although I'm not convinced it is specific to the OS version).
I did install Keepass around 1.22 while running Windows 7, which then have been migrated using the Windows 8 upgrade installation, so the issue could also be related to updating Keepass from older versions, or coupled to the Windows migration, but I believe it to be easy to reproduce.
The steps needed to reproduce the bug(s) on my end:
(Prerequisite is "Minimize to tray instead of taskbar" I believe)
Now, the main Keepass window will dissapear, the tray icon will indicate that the database is locked, and depending on what you do next the results will be interesting.
I have not yet had the guts to try the OK button, seeing as I'm getting enough problems already. :)