Upper( Substitute ( From ; [¶ ; ""] ;[" ";""] ) )
Upper( Substitute ( From ; [¶ ; ""];[" "; ""] ) )
Substitute can do multiple substitutions. You wouldn't need Trim anymore as the spaces are already handled by Substitute. Also it appears that you're converting paragraphs to spaces, but it seems like your goal is to convert them to nil, which is done with an empty pair of quotes.