# new line character

**URL:** <https://tech-community.robotics.abb.com/t/new-line-character/2511>\
**Category:** Robot Controller\
**Created:** [February 11, 2009, 6:34pm UTC](https://tech-community.robotics.abb.com/t/new-line-character/2511 "2009-02-11T18:34:39Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jhweppler](https://avatars.discourse-cdn.com/v4/letter/j/e9c0ed/32.png) [@jhweppler](https://tech-community.robotics.abb.com/u/jhweppler)\
**Post date:** [February 11, 2009, 6:34pm UTC](https://tech-community.robotics.abb.com/t/new-line-character/2511/1 "2009-02-11T18:34:39Z")

</div>

how do I add a newline character to the end of a string??

---

<div class="post-metadata">

**Author:** ![RussD](https://avatars.discourse-cdn.com/v4/letter/r/dec6dc/32.png) [@RussD](https://tech-community.robotics.abb.com/u/RussD)\
**Post date:** [February 11, 2009, 8:10pm UTC](https://tech-community.robotics.abb.com/t/new-line-character/2511/2 "2009-02-11T20:10:48Z")

</div>

Probably "  
", it might depend on the usage though.

---

<div class="post-metadata">

**Author:** ![jhweppler](https://avatars.discourse-cdn.com/v4/letter/j/e9c0ed/32.png) [@jhweppler](https://tech-community.robotics.abb.com/u/jhweppler)\
**Post date:** [March 25, 2009, 4:32pm UTC](https://tech-community.robotics.abb.com/t/new-line-character/2511/3 "2009-03-25T16:32:31Z")

</div>

I tried using " " but it gave me “unexpected unknown token” errors. What I really need is a newline character and a carriage return character which in most other languages that I’ve used would be represented as " ". Has anyone else ran into this problem? Does anyone have a solution or can this not be done using RAPID Strings??

Thanx

---

<div class="post-metadata">

**Author:** ![RussD](https://avatars.discourse-cdn.com/v4/letter/r/dec6dc/32.png) [@RussD](https://tech-community.robotics.abb.com/u/RussD)\
**Post date:** [May 29, 2009, 2:22pm UTC](https://tech-community.robotics.abb.com/t/new-line-character/2511/4 "2009-05-29T14:22:08Z")

</div>

Try something like this:

str1:=“Line11310”+“Line21310”+“Line310”;

You can append control characters to string literals with “XX”, where XX is the hex value of the control character.

Note that this does not work with instructions like TPWrite, probably only works with write instructuions to files or ports.
