Added preliminary error dialog support to Connect.
Fixed page unload displaying error dialog.