changed error messages to QString.arg()