Write data to an XML file (GRW for PHP)

You can have the data write to an XML file, instead of writing to a report.

  1. Create a copy of the Report Writer environment set.
  2. Add a new environment variable:
    • Type: Value
    • Name: GREDATAFILE
    • Value: filename.xml, where filename will be the name of the created file.
  3. Make the following changes to the ReportLauncher.php file:
    • Comment out the following lines, as follows (using //):
      //  echo "PDF Report File created: ".$reportFileName."\n";
      //  echo "Done.\n";
    • Add the following line:
        echo "XML file created.\n";
  4. Select your new Report Writer environment set, and de-select the original Report Writer environment set.

    Figure: Report Writer Environment Set example


    Screen shot showing copy of Report Writer environment set, with addition of GREDATAFILE environment variable highlighted.
  5. From Genero Studio, execute the ReportLauncher application.