function generateWindow(tabledata)
{
  var analyzer = window.document.getElementById("analyzerprg");
  neuesFenster = open("", "displayWindow","height=600,width=700,menubar,toolbar,scrollbars,resizable,dependent");
  neuesFenster.document.open();
  with (neuesFenster.document)
  {
      write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">\n");
      write("<html>\n");
      write(" <head>\n");
      write("  <meta http-equiv=\"Content-Type\" content=\"text/html;charset=utf-8\">\n");
      write("  <title>Druckausgabe proALPHA Analyzer</title>\n");
      write("  <script type=\"text/javascript\"> ");

      // provides the posibility to have output with another language (available with InfoZoomApplet.jar Versio 2.0R34)
      applang   = analyzer.getLanguage();

      //outcomment the following line, if you do not want an automatic print dialog:
      //write("window.print();");

      write("</script>\n");

      // outcomment following line, if you do not want to use a stylesheet:
      // or use a different stylesheet, depending on applang
      write("  <link rel=\"stylesheet\" href=\"../css/pa-appletprint.css\" type=\"text/css\">\n");  //path absolute to webserver-root

      write(" </head>\n\n");
      write(" <body>\n");
      write("  <p align=left><b><a href=\"http://www.proelectro.de/\" target=\"_blank\">www.proelectro.de</a></b><br>\n");

      //These lines put the specification (if any) on top of the print preview:
      spec      = analyzer.getSpecificationAsHTMLTable(50); // maxLength  // -- don't use InfoZoom as infozoom
      numattr   = analyzer.nrOfAttributes();                              // -- take care of capitals as in w_oinz00.w/w_oinz03.w
      objstring = analyzer.getObjectsString();


      if (spec != "")
      {
          write("  <h4>Ihre Spezifikation:</h4>\n\n");
          write(spec);
          write("\n");
      }



      if (applang=="german")
      {
        write("  <h3>Ihre Auswahl:</h3>\n");
        write("  "+analyzer.nrOfRecords()+" von "+analyzer.nrOfAllRecords()+" "+objstring+" (Attr: "+numattr+") <p>\n\n");
        }

      else
      {
        write("  <h3>Your Choice:</h3>\n");
        write("  "+analyzer.nrOfRecords()+" of "+analyzer.nrOfAllRecords()+" "+objstring+" (Attr: "+numattr+") <p>\n\n");
        }

      write(tabledata); // This is the table to print
      write(" \n");
      write(" </body>\n");
      write("</html>\n");
  }
  neuesFenster.focus();
  neuesFenster.document.close();
}


