"\n" not working
Hi,
We are having the below code to display the content to the user.
{JAVA}
if (thisValue().length() > 0 && thisRef().hasValidValue())
{
String orgStr = thisValue();
int length = orgStr.length();
String nextlineStr = "\n";
if(length>15)
{
orgStr = orgStr.substring(0,17) + nextlineStr + orgStr.substring(17,orgStr.length());
for (int i=18;i+17<=length; i=i+17)
{
orgStr = orgStr.substring(0,i)+orgStr.substring(i,i+17)+ nextlineStr+ orgStr.substring(i+17,orgStr.length()); }
}
saveValueSet("result", orgStr);
}
else
{
saveValueSet("result", thisValue());
}
{/JAVA}
The Probelm for us is "\n" is not working. Instead of going to the next line it is adding a space. Anyone faced this issue before?
PEGA Version 5.5