Skip to main content
10-Marble
November 1, 2025
Solved

String issue with carriage return (new line) between Mathcad Prime version 10.0.1 and 11.0.1

  • November 1, 2025
  • 1 reply
  • 409 views

Why doesnโ€™t Mathcad Prime 11.0.1 no longer accept ASCII code [13] for carriage return (new line)?

It appears to work in version 10.0.1 but not in 11.0.1. Is this true for everyone else or just me?

I have both versions on the same computer--is there something I am missing? 

 

LarryJ_0-1762038888849.png

 

Best answer by StuartBruff

Yes, it is true for everyone else.

 

There is a workaround - use 133 instead of 13.  But if you want to write such strings to a file, take note of Werner's comments near the end of the following thread.

 

https://community.ptc.com/t5/Mathcad/Problem-Report-newline-character-no-longer-works-in-a-string/m-p/1033331#M218687

 

Stuart

1 reply

23-Emerald V
November 2, 2025

Yes, it is true for everyone else.

 

There is a workaround - use 133 instead of 13.  But if you want to write such strings to a file, take note of Werner's comments near the end of the following thread.

 

https://community.ptc.com/t5/Mathcad/Problem-Report-newline-character-no-longer-works-in-a-string/m-p/1033331#M218687

 

Stuart

LarryJ10-MarbleAuthor
10-Marble
November 2, 2025

Thank you so much for the quick informative response. I had a Prime number worksheet that displays the results which needs the CR for the output otherwise the results go off the paper (see attached)

23-Emerald V
November 2, 2025

Neat.  I've also used the string breaking for similar purposes ... IIRC, prime numbers were such a use and a few OEIS sequences.

 

2025 11 02 A.png

 

  • Right justification without a monospaced font looks silly, and left justification can look a bit ragged with a proportional font.
  • The strreplace wasn't needed; a strjoin on ", " would have sufficed, but I was testing a modified strreplace function.
  • The string justification functions have wider applicability than just sequences.  Where would cowsay be without it?

 

Stuart