Start a new topic

Soft returns in "Find and Replace" window


I can type soft returns in CT's editor pane, but I can't in the "Find and Replace" window...

 For some reason CT inserts hard returns instead of soft ones when it gives a perfect match. I have hundreds of soft returns in my source segments and I need to replace them one by one manually each and every time in the target perfect matches... (my files are Excel files converted to sdlxliff by the client). In Studio the leading and trailing returns are excluded from the Editor's segments, but for some reason they are not in CT. :-(

So... any suggestion to quickly replace all the hard returns to soft ones in CT?

A rather strange editor, Tex-Edit Plus, shareware (worth every penny of the USD 15), with heaps of AppleScripts, 199 available here. Some CT users have dismissed it, though.


In the DejaVu group (Yahoo), something similar came up. I don't use DV anymore (since I don't use Windows), but maybe you can "borrow" from the solution below:

A quick workaround of those pesky soft returns: Import, export into an 
EV, check whetehr the file includes any hard returns. If not, copy 
source to target, hide the source and IDs, batch replace soft returns 
with hard returns in the target. You might like to hide all tags as 
well. Reimport as a new SOURCE file. Translate the nicely segmented and 
clean text. Export, unhide and reimport the EV back into  your initial 
source file.

Sounds more complicated than it actually is. It gives you some extra 
work but it's well worth it with large-ish files.


Thanks woorden,

Aaaargh, the package cointains over 60 files (crying)...

And if I understand that would remove the soft returns, so the files will be a mess when reimported in Excel by the client.

AC: the package cointains over 60 files


If you installed TE+, and ran Automator, you'll find lots of TE+ actions you can save as Folder Actions to batch convert. Including the one I think you need.


Woorden, thank you for all you sugestions. I don't have enough time anymore to make further tests ( installed TE+, but I got garbage characters for my Japanese source segments and I didn't find the option to use UTF-8.

I'm back to CT for the final check, since the package contains a few bigs files that... Studio itself cannot save (insufficient memory error).

I deactivated the auto-propagation options, so that CT stops replacing my soft returns with hard ones. I hope this do the trick..

Time for that Igor to wake up. To me, this seems way more important than most of the REQs I've seen lately.


Hi Alain,

Try the following to convert your soft returns to hard returns in target segments:

1. Close and open the sdlxlif project again in CT.

2. Set the translated status for target segments in the Task menu.

3. Save the project.


Thank you Igor, it works!

I can't believe it was so simple.

AC: it works!

I believe it. Igor's solutions usually work. But why? As far as I can see, he might as well have said, "Close the project, walk around the church three times, open it again." 

Besides, this procedure will have to be repeated for each file, of the 50+.


Woorden, I glued all files in CT,  so there was no need to do it for every single file.

But still, somes files (the big ones) are corrupted... but this problem initially comes from Studio (there were a few error messages when Studio opened the files), nothing to do with CT.

AC: I glued all files in CT

Smart enough. So only one question left, "Why does Igor's trick work?"


Hi Hans,

When loading Trados files, CT performs some checks for the line breaks and corrects them if needed. Therefore, simple opening the file does the trick.


IK: simple opening the file does the trick.

Great! And how does the finding and correcting of the line breaks work?


The program finds soft returns (which rule in the Unix ad Java world) and replaces them with hard returns (Windows).


Igor, does that mean that the Excel file soft returns will be replaced with hard returns? If so, the resulting Excel file will have more cells than the original one. Or am I missing something? 

Login to post a comment