3 Replies Latest reply on Dec 16, 2009 10:30 PM by (MightyJack)

    Text encoding mac - PC [JS]

    (MightyJack) Level 1

      Hi there

      I am running a script there is writing a log file for processing on a pc server (Notes). I run my script on a Mac and save the script to a share.


      My question is :

      Is there a way to write PC compatebel file and getting the right line break ?


      this is some of the test i have done:


      function myWriteLogfile(myLogText, myLogFilePath){


      var myFilePath = myLogFilePath ;

      var myFile = new File (myFilePath);

      var myFileOpen = myFile.open("e","UTF-8");

      if (myFileOpen) {


          myFile.write (myLogText+"\r"+"\n");





      and "\n"+"\r");    and I have tried to open the file with the "\uFEFF" first.


      Hoping someone can help