code: private void onBrowserError(I_CmsUploadDialog dialog, String errorCode) {
  
          int code = new Integer(errorCode).intValue();
          String errMsg = org.opencms.gwt.client.Messages.get().key(org.opencms.gwt.client.Messages.ERR_UPLOAD_BROWSER_0);
  
          switch (code) {
              case 1: // NOT_FOUND_ERR
                  errMsg = org.opencms.gwt.client.Messages.get().key(
                      org.opencms.gwt.client.Messages.ERR_UPLOAD_BROWSER_NOT_FOUND_0);
                  break;
              case 2: // SECURITY_ERR
                  errMsg = org.opencms.gwt.client.Messages.get().key(
                      org.opencms.gwt.client.Messages.ERR_UPLOAD_BROWSER_SECURITY_0);
                  break;
              case 3: // ABORT_ERR
                  errMsg = org.opencms.gwt.client.Messages.get().key(
                      org.opencms.gwt.client.Messages.ERR_UPLOAD_BROWSER_ABORT_ERR_0);
                  break;
              case 4: // NOT_READABLE_ERR
                  errMsg = org.opencms.gwt.client.Messages.get().key(
                      org.opencms.gwt.client.Messages.ERR_UPLOAD_BROWSER_NOT_READABLE_0);
                  break;
              case 5: // ENCODING_ERR
                  errMsg = org.opencms.gwt.client.Messages.get().key(
                      org.opencms.gwt.client.Messages.ERR_UPLOAD_BROWSER_ENCODING_0);
                  break;
              default:
                  break;
          }
          dialog.showErrorReport(errMsg, null);
      }
docs: Switches the error message depending on the given error code.<p>
  
  The error codes are defined in the W3C file API.<p>
  
  <a href="http://www.w3.org/TR/FileAPI/#dfn-fileerror">http://www.w3.org/TR/FileAPI/#dfn-fileerror</a>
  
  @param dialog the upload dialog
  @param errorCode the error code as String