Skip to main content
Version: V3 (Ignition 8.3)

system.mes.dashboard.importFromCsv

Description​

Imports Dashboard Widgets from a CSV file provided as raw bytes. The service parses the CSV content and creates or updates widgets and their metadata accordingly.

Permissions​

This method requires the DASHBOARD.WRITE.SAVE permission.

Syntax​

system.mes.dashboard.importFromCsv(bytes)

Parameters​

ParameterTypeNullableDescription
bytesByte[]FalseThe CSV file content as raw bytes.

Returns​

An ApiResponse object indicating success or failure of the import.

NameTypeDescription
successBooleanIndicates if the import was successful.
messageStringDetails about the import outcome.
dataIntegerThe number of widgets imported (when successful).
errorStringError details if the import failed.

Code Examples​

Perspective File Upload (onFileReceived)​

def runAction(self, event):
csvBytes = event.file.getBytes()
response = system.mes.dashboard.importFromCsv(csvBytes)
print(response)