Skip to main content
Question

Text File Writer is prefixing each line with a 'space' character


benvk
Contributor
Forum|alt.badge.img+7
  • Contributor

Has anyone had an issue when writing to text file, it prefixes each entry with a 'space' character?

It is writing each new line nicely, appending to the existing data, but the data it writes always is inserted with a leading space.

I can confirm the row being sent to be added to the text file does not have any leading space:

When this is written, a space is appearing!

2 replies

takashi
Evangelist
  • June 27, 2020

Where do the source text lines come from?

Didn't the AttributeTrimmer work to trim the space character?


benvk
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • June 27, 2020
takashi wrote:

Where do the source text lines come from?

Didn't the AttributeTrimmer work to trim the space character?

yes it does trim the character, I can see the attribute does not have a leading space right before being inserted to the text writer (as per above screenshot).

source is an attribute manager where I build that string, right before inserting into the text writer.

Note I have just tried using a CSV writer and it works perfectly fine, so that tells me the string being inserted is fine, it is the text file writer appending the leading space.

I no longer need an answer to solve this projects issue, but now I am just curious as to why it added the space in the first place.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings