Reports generation tutorial, create and test a text report.
Tutorials → Reports | Tutorial | How-to Guide | Reference
This Tutorial Teaches you to:
- Create text reports with real-time data
- Set up automated report generation
Prerequisites:
1. Create a Simple Text Report
We'll create a shift report showing tank status.
- Navigate to Reports → Forms
- Click first row to add new form
- Configure:
- Name:
ShiftReport - SaveFormat:
Text - SaveFileName:
C:/Reports/Shift.txt
- Name:
- Press Enter
Mandatory Folder
It is mandatory that the folder where the Report will be saved, must be created before. The system does not create folders automatically.
2. Design Report Content
- Go to Reports → Forms Editor
- Double click
ShiftReport - Enter the report template below, then Save the report:
================================
TANK FARM SHIFT REPORT
Date: {Server.DateTimeInfo.Date}
Time: {Server.DateTimeInfo.Time}
================================
TANK STATUS SUMMARY
-------------------
Tank 1:
Level: {Tag.TankFarm/Tank1/Level} ft
Temperature: {Tag.TankFarm/Tank1/Temp} °F
Pressure: {Tag.TankFarm/Tank1/Pressure} PSI
Status: {Tag.TankFarm/Tank1/Status}
Tank 2:
Level: {Tag.TankFarm/Tank2/Level} ft
Temperature: {Tag.TankFarm/Tank2/Temp} °F
Pressure: {Tag.TankFarm/Tank2/Pressure} PSI
Status: {Tag.TankFarm/Tank2/Status}
PRODUCTION METRICS
------------------
Total Volume: {Tag.TankFarm/Metrics/TotalVolume} gal
Flow Rate: {Tag.TankFarm/Metrics/FlowRate} gpm
Daily Production: {Tag.TankFarm/Metrics/DailyProduction} gal
================================
End of Report
3. Test Report Generation
- Start runtime
- Open PropertyWatch
- Go to List2 and type: Report.Form.ShiftReport.Save
- Change the value from 0 to 1
- Check the folder to see generated report
4. Schedule Automatic Reports
Create scheduled task for shift reports:
- Go to Reports → Forms
- Change the SaveTrigger to: Server.Hour
- The report will be generated every hour once the solution is running.
5. Monitor Report Status
- During runtime, open Reports → Reports Monitor
- Verify report status:
- Name: ShiftReport
- LastStatus: 0
- SavedFileName: Shows generated file path
- Check for any errors in LastStatusMessage
→ Modules / Business Operations / Reports Module → Tutorials / Business Operations / Reports Module Tutorial → How-to Guides / I Business Operations / Reports Module How-to Guide → Technical Reference / Business Operations / Reports Module ReferenceReports Module Links
Explanation - to understand concepts
Tutorials - to learn by doing
How-to Guides - to accomplish specific tasks
Reference - technical details
In this section...