You are reading a single comment by @Gordon and its replies. Click here to read the full conversation.
  • I think your issue was e.data != "\r" || e.data != "\n" because it'll always be true - it should be e.data != "\r" && e.data != "\n"

    I guess the thing to do is to use the \r as a signal that the data has ended:

    if (e.data == "\r" || e.data == "\n") {
      print(myValue);
      myValue="";
    } else {
      myValue+=e.data;
    }
    
About

Avatar for Gordon @Gordon started