Add preliminary error messages to exceptions
Add errorcodes to the exception classes