// Get the field value as a string
var t = getField("ActionAgenda").valueAsString;
// Replace carriage returns with nothing
t = t.replace(/\r/g,"");
// Set the field value to altered string
getField("ActionAgenda").value = t;
Thank you for your help, George.
The script works perfectly to replace carriage returns in a text field.
Can you please advise how to modify the same script to remove a blank line instead of a carriage return?
Thanks again, George.
You're need to define exactly what you mean by "blank line".
What I need to do is go to the last carriage return in the multiline text box and remove it.