6/9/2025 11:25 AM | |
Joined: 3/27/2024 Last visit: 8/1/2025 Posts: 18 Rating:
|
Hello, i am curently working on tia portal v19 with HMI MTP1500 Unified comfort, i would like to export alarms and save them on USB (X61) , i use this script but a csv file is not created.
export function showControlPanel_1_OnTapped(item, x, y, modifiers, trigger) { let timeStamp = new Date().toLocaleDateString().replace(/[/]/g, '_'); let delimiter = ','; let languageID = 1033; let csvData = "ID" + delimiter + "Raisetime" + delimiter +"AlarmClassName" + delimiter + "AlarmText"; HMIRuntime.FileSystem.WriteFile(fileName, csvData, "utf8"); }).catch ((errCode)=> { }); Thanks in advance ------------------------------------------------------------------------------------------ |
Last edited by: Moderator_Lan at: 06/10/2025 09:13:10New subject after splitting |
|
6/27/2025 9:25 AM | |
Joined: 8/3/2009 Last visit: 9/10/2025 Posts: 16386 Rating:
|
Hello mayssa_slimen145 use the Trace viewer for debugging the Script, perhaps it crashes somewhere: https://support.industry.siemens.com/cs/de/en/view/109777593 also the path seems not to be right, should be something like: /media/simatic/X61/... Bye Murof |
Last edited by: Murof at: 06/27/2025 09:27:01Last edited by: Murof at: 06/27/2025 09:27:17If this Information really helps, you could use the Rate function |
|
Follow us on