public int loadProject( File file)
  {
    int back = -1 ;

    TProject dummy = null ;
    try
    {
      dummy = this.readXmlFile( file ) ;
    }
    catch ( SAXException sxe )
    {
//      sxe.printStackTrace() ;
      back = 1 ;
    }
    catch ( ParserConfigurationException pce )
    {
//      pce.printStackTrace() ;
      back = 2 ;
    }
    catch ( IOException ioe )
    {
//      ioe.printStackTrace() ;
      back = 3 ;
    }
    catch (Exception e)
    {
      back = 4 ;
    }
    catch (Error er)
    {
      back = 5 ;
    }

    if (dummy != null)
    {
      dummy.setProjectFile(file);
      // all data are up to date
      dummy.setUnSaved(false);

      this.addProject( dummy ) ;
      this.setCurrentProject( dummy ) ;
      back = 0 ;
    }

    return back ;
  }