- Added Message box handling.

- Clean of unused code.