Update CreateWindow to capture and report errors correctly
Merge pull request #77 from jubalh/master

Update CreateWindow to capture and report errors correctly