Write List to File error



  • Hi
    I am trying to write this List which contains these (copied from debugger) :
    LIST_WITH_IMAGES_LOCATIONS: [
    "C:\Users\Joy\Desktop\BasFiles\images\3.jpg",
    "C:\Users\Joy\Desktop\BasFiles\images\4.jpg",
    "C:\Users\Joy\Desktop\BasFiles\images\6.jpg"
    ]

    But i am getting this error :
    [04:17:45] Thread #1 : SyntaxError: Parse error Line number:2 During execution of script { _sa(221739095); native("filesystem", "writefile", JSON.stringify({path: C:/Users/Joy/Desktop/BasFiles/Images.txt,value: (VAR_LIST_WITH_IMAGES_LOCATIONS).join("\r\n") + ((false) ? "\r\n" : "" ),base64:false,append:false})) section_start("test", 31804012,function(){ })}

    Please help. Thanks


  • administrators

    @niceusername You are using pathname with type expression. Switch it to string.



  • Thank you! it worked, i was using [[VARIABLE]]/Images.txt with expression, it was also giving me error but then i used it with string then it worked. I thought in string, variables values cannot be used :)


Log in to reply
 

Looks like your connection to Bablosoft was lost, please wait while we try to reconnect.