CSV Export
This function block facilitates the logging and export of data into a CSV file format. It allows users to specify the file path, file name, and conditions for starting the logging process and exporting the data.
📥 Inputs
Folder Path
The directory where the CSV file will be saved.
File Name
The name of the CSV file to be created.
Start Logging
A boolean that, when set to true, begins logging the incoming data.
Export File
A boolean that triggers the export of logged data to the specified CSV file.
Data_{i}
Up to ten generic data inputs. Each can receive data that you want to log into the CSV file.
📤 Outputs
This function block does not produce any outputs.
🕹️ Controls
Set Data Headers
Users can enter custom headers for each data input field to label them appropriately in the CSV file.
🎨 Features
Dynamic Logging
Effectively logs data in real-time when the start logging condition is met.
Automatic Header Management
Automatically creates or updates headers in the CSV file based on the user-defined headers.
Error Handling
Comprehensive error messaging helps users troubleshoot issues related to file permissions or read/write operations.
📝 Usage Instructions
Specify Folder and File Name: Connect the
Folder Path
andFile Name
inputs to determine where and how the CSV file will be saved.Configure Headers: Enter the desired headers for your data fields in the header text boxes.
Start Logging: Send a
true
value to theStart Logging
input to begin capturing data.Export Data: To export the logged data to CSV format, send a
true
value to theExport File
input.
📊 Evaluation
When the conditions are met, this function block logs the incoming data along with the specified headers into the chosen CSV file. It handles the creation of a new file or updates an existing one, maintaining data integrity.
💡 Tips and Tricks
🛠️ Troubleshooting
Last updated