The header row in an HMI trend log .txt file is a panel software feature, not switched on in the project. The 2.42 build writes the columns with no labels; the 2.51 release writes each trend tag name as its header. Back up the project, upgrade from the maker's download, keep tag names at 7 characters or fewer, and document the two-tab offset.
A trend log full of numbers with no labels slows the whole reporting chain down: the manager asks where the headers are, and somebody types them in by hand each time. The header row in the .txt file a Line Trend Graph writes to a USB stick is not a project setting. It is a panel software feature: the older build writes the columns bare, and the release that added the header row takes its text from each trend tag name. The fix runs in this order: read the installed version, back up the project, update the panel from the maker's own download, then set tag names and an import step that keep the headers sitting over their columns.
Why the file has no header row
The header row is a feature of the panel software itself. Version 2.42 writes the data columns only. Version 2.51 added the row, and the text of each header is the trend tag name. On 2.42 there is no setting that makes the panel add the row, so the answer is a software update, not a change in the trend object. Everything else on this page depends on which build the panel runs, which is why the version comes first.
Symptoms and what each points to
- Numbers only, no first row of names: the panel software predates the header feature. Read the installed version.
- A header row is present but the names sit over the wrong columns: the file advances to a tab stop every 7 characters, and a name longer than 7 characters crosses a stop. Shorten the tag names.
- The header row starts one column to the right of the first data column: that is how this file lays the row out. Handle it in the import step, not by retyping headers.
- You cannot tell which trend wrote the file: the log file name is filled in from the screen number and the object name, so match the file to the trend screen before blaming the trend.
Check the version and the file first
Read the installed version from the panel, or from the maintenance record if the panel must stay running. It is the same check you run to verify the installed HMI software version after an upgrade, and it decides the path from here.
Then confirm you are reading the right file. The trend object fills in its log file name from the screen number and the object name, so each trend on the panel writes its own file on the stick. Trigger a short test log and confirm the file you plan to fix is the one this trend writes.
The decision at this point: at 2.42 the update is the fix. At 2.51 or later, a missing header row points at the wrong file or the wrong project on the panel, so sort that out before touching the software.
Back up the project, then update the panel
- Back up the project first, and keep the copy off the USB stick you log to. The steps are in back up and restore an HMI panel project the safe way, and they matter here because an update that goes wrong has to end with the panel running its project again.
- Confirm the target release supports the panel model and opens your project. The HMI software upgrade prerequisites check belongs before any update file is copied, not after.
- Take the update only from the panel maker's own support pages or its distributor, and follow the maker's documented update procedure for the model.
- Apply the update in a maintenance window with the process in a safe state. A panel that is logging a running furnace is not the place to try new software.
- After the update, download the project back to the panel and confirm the screens and the PLC link behave normally before the panel returns to logging duty.
Set tag names that survive the export
From the release that writes headers on, the header text is the tag name. That makes the tag name a label engineering and QA read at the top of every file, so name the trends for people, not for the project tree. The layout gives a second reason to keep names short: the file advances to a tab stop every 7 characters, and a name that crosses a stop pushes the headers behind it off their columns. Keep every logged trend tag name at 7 characters or fewer. Renaming happens in the project, which is one more reason the backup came first.
Example: three furnace tag names against a 7-character tab stop
Inputs:
- Tab advance: 7 characters, the spacing this log file uses.
- Tab stops: characters 7, 14 and 21, which is where a 7-character advance puts them.
- Tag names:
Temp1,BeltSPandZoneTemp, three names of the kind a furnace logging project carries for a zone temperature and a belt speed.
Rule in words: the header row advances to the next tab stop after each name. A name of 7 characters or fewer stays inside one stop, so the tab that follows lands the next header on the stop where the data columns sit. Each character past 7 lands in the next stop, and the tab that follows jumps one stop further than it should.
Arithmetic:
Temp1is 5 characters. 5 is under 7, so the tab jumps to the stop at character 7 and the next header starts at character 8. One stop, and it lines up.BeltSPis 6 characters, same result: tab to character 7, next header at character 8. Lines up.ZoneTempis 8 characters. Characters 1 to 7 fill the first stop and character 8 sits in the second stop, characters 8 to 14. The tab jumps to the stop at character 14, so the next header starts at character 15 instead of character 8. Every header afterZoneTempsits 7 characters, one full stop, to the right of its data.
Result: two of the three headers sit over their columns, and the 8-character name shifts every header behind it.
Decision: keep the name inside one stop and the row holds. Rename ZoneTemp to ZoneTmp, 7 characters, and all three headers land over their columns. Any name of 8 characters or more costs one extra tab stop per stop it crosses.
The two-tab offset at the first column
In this file layout the header row does not begin at the first data column. Two presses of the Tab key before the first header bring the row over the columns. Put that offset into the saved import template or spreadsheet once, so every file is corrected the same way and nobody has to rediscover it on a busy day. Do not repair alignment by typing spaces, because spaces push the characters that follow off the tab stops and look identical to a tab on screen.
Keep the header spreadsheet until the export passes
Until the maintenance window opens, run the workflow that predates the header row: a saved spreadsheet with the header row typed once, one column per trend, and each new log pasted under it. It keeps labeled data in front of engineering and QA while the upgrade waits its turn. Retire the pasting only after a test export from the updated panel passes the checks below.
Test the new export before you rely on it
Run the Line Trend Graph long enough to write a fresh file to the USB stick. Open it in a plain text editor before any spreadsheet touches it, because a spreadsheet hides where the tab characters sit. Confirm four things: the file is new, the header row is present, each header reads exactly as its tag name, and the first value under the first header is a reading you recognize from the process.
Check the date on the file too. A trend log file on USB rolls over at midnight, so yesterday's file can sit there looking current; the detail is in how an HMI trend log file rolls over at midnight on USB. Keep the passing test file as the baseline for the next software or project change.
Which fix fits which panel
- Panel on 2.42, headers wanted: take the upgrade path in the order above. The update is the only thing that makes the panel write the row.
- Panel on 2.51 or later, headers present but misaligned: shorten every logged tag name to 7 characters or fewer and put the two-tab offset into the import template.
- Upgrade waiting on a change window: keep the saved header spreadsheet running and paste under it.
Recommendation: If engineering or QA reads these logs every shift, book the maintenance window and take the upgrade path: back up the project, confirm the prerequisites, update from the maker's own download to the release that adds the header row, rename every logged trend tag name down to 7 characters or fewer, and build the two-tab offset into the saved import template. If the window will not open soon, keep the saved header spreadsheet running and paste each log under it, then move to the upgrade when the panel can come offline safely.
Questions
How do I keep the headers in their own columns when the file opens in a spreadsheet?
Open the file through the spreadsheet's text import and choose tab as the delimiter, so each column lands in its own cell in the same order as the text file. Pasting raw text into a sheet can drop everything into one cell or split on the wrong character, which hides the real column boundaries. Import once, save the import settings with the template, and every later file uses the same step.
How can I tell a tab from a space in the log file?
Search for the tab character in a plain text editor, or switch on the editor's formatting marks so tabs and spaces display differently. The header row lines up because tabs land on the stops every 7 characters; a space typed by hand breaks that without looking different on screen. If a column will not sit over its data, delete the spaces before that header and let a tab character do the work.
Do headers appear in files the panel wrote before the upgrade?
No. The panel writes the header row when it creates the file, so only files logged after the update carry the tag names. A file the 2.42 build wrote keeps its headerless layout even after the panel is upgraded. Keep the header spreadsheet for the archived files, or type one header row at the top of an old file when engineering needs to publish it.
Planning information, not legal or engineering advice. Rules differ by place: check codes and permits with your local authority and your licensed trades.