mardi 3 mars 2015

returning new line in notepad editor using javascript

I have this javascript code in a mirth channel that retrieves data from a query and sends the output to the destination in a .txt format. When a result is fetched, i want it to be on a single line. In other words, i want the result to be on a single line each time. I also tried "<br/>" but didn't work too.



var xmlMs = ''
var i = 0;
while (result2.next()){
xmlMs += 'Count:' + ++i + "\n\r";
xmlMs += 'No:' + result.getInt(1) + "\n\r";
xmlMs += 'Date:' + result.getDate(2) + "\n\r";
xmlMs += 'Time:' + result.getTime(2) + "\n\r";
}
test.add(xmlMs);
return test;

Aucun commentaire:

Enregistrer un commentaire