Handling MS Word {REF} fields in SDL Studio 2011
Thread poster: johnyaku

johnyaku  Identity Verified
Local time: 19:16
Japanese to English
Oct 13, 2012

What is the best way to handle {REF} fields in SDL Studio 2011?

I found an old (2007) post saying that Trados cannot handle {REF} fields, but I assume that that post was referring to Trados 2007. Hopefully this issue has been fixed in the last five years.

I am using SDL Studio 2011 to translate a set of MS Word 2003 documents where every third sentence contains a {REF} field. I can place the {REF} field in the target segment, but I cannot edit the value of the field, which means that when I create the target Word document the field is displayed in the source language. There are too many of these references for editing the target document to be a practical option.

I assume that this is a common/well-known problem, but I couldn't find anything in the forum.

Suggestions?


Direct link Reply with quote
 

johnyaku  Identity Verified
Local time: 19:16
Japanese to English
TOPIC STARTER
Handling MS Word {REF} fields in SDL Studio 2011 - Partly solved Oct 13, 2012

I have a partial solution, and I'll record it here in case other people have the some frustration.

1) Drop the placeable corresponding to the {REF} field in the appropriate place in the translation. Don't worry about translating it at this point.

2) Translate the segment that the {REF} field is pointing to. (No need to track down which segment this is unless you want to verify that this procedure works -- you'll translate it eventually anyway.)

3) Generate the target translation to create Word file in the target language. At this point, the {REF} fields will be displayed with their original values in the source language - the problem that I was originally trying to solve.

4) Select all of the text in the document (Ctl+A) and then press F9 to update all of the fields in the document, this replaces the value of the {REF} field with the new value in the target language.

I'm still having formatting problems with these tags, but I think I can work that one out.


Direct link Reply with quote
 

Emma Goldsmith  Identity Verified
Spain
Local time: 09:16
Member (2010)
Spanish to English
Interesting. Oct 13, 2012

Thanks for telling us how you solved this problem, Johnyaku. I remember seeing the issue some time ago, so now I know what to do if it crops up again in the future.

Direct link Reply with quote
 

Abrigela
Local time: 09:16
Hungarian to English
+ ...
This is confusing for me Oct 13, 2012

Hello,

I always thought that fields were the result of information coming from somewhere else. So I would not translate them, rather I leave them to be populated again from the origin of the data. If my client wants these fields translating then I would expect the data for these. Are you referring to something else?

Thank you

Abrigela.


Direct link Reply with quote
 

johnyaku  Identity Verified
Local time: 19:16
Japanese to English
TOPIC STARTER
Formatting problem remains Oct 21, 2012

After Step 3) in the procedure above, the reference fields in the target translation are displayed in the source language, but with the appropriate formatting.

When I press F9 in Step 4) the reference fields are updated to the target language, but the formatting is totally mangled. The font changes, and the first word uses the same font size as the surrounding text, but the second and subsequent words are in bold and a larger font size.

This does not happen when I simply overwrite the Word document, so this is an artificat of SDL Studio 2011 processing.

I have to submit this job in a couple of hours, so I have spent the last couple of hours manually reformatting a 13,000 word document, but I don't really want to have to do this in future.

It gets worse.

I then thought "I wonder what happens if someone updates one of the references, and then presses F9 to update all references." So I backed up the file and tested it to see what would happen.

Now all the formatting is trashed again, including the backup file.

Not impressed.


Direct link Reply with quote
 

SDL Community  Identity Verified
United Kingdom
Local time: 09:16
English
Confused... Oct 22, 2012

Hi,

I'm with Abrigela on this one. Where is feed for the field coming from? If you can't translate the source of the information being fed into the field then I wouldn't expect this to work at all. Or maybe I'm also confused?

Maybe it fed through the available document properties and you just need to ensure they are being extracted as translatable text?


If you can share the document I'll gladly take a look for you and see if I can help?

Regards

Paul
pfilkin@sdl.com


Direct link Reply with quote
 

johnyaku  Identity Verified
Local time: 19:16
Japanese to English
TOPIC STARTER
{REF} fields point to other parts of the document Oct 22, 2012

Abrigela: You're right. The {REF} fields are populated by information from somewhere else. In this case, "somewhere else" means another part of the same document. So I can translate the source being fed into the field.

For example, this document has an appendix called "Appendix A: Shortcut Keys". Elsewhere in the document there are several references to this appendix, such as "For a full list of shortcuts, refer to {REF *pointer to the bookmark for Appendix A*}.

The "content" of the "{REF *pointer to the bookmark for Appendix A*}" field is determined by the content of the bookmark being pointed to.

Initially when I perform a "Generate Target Translations" batch task, the content of these fields is displayed in the source language rather than in the target language. However, I can fix this by selecting all of the text and using F9 in Word to update all references.

The problem is that the formatting becomes totally whacko.

For example, in the original document the content of the {REF} fields was in plain text (no bold, italic, etc.) But when I update the references in Word using F9 the first word of the content is in plain text, but the second and subsequent words are in bold. There are also issues with the fonts and font sizes, as described previously.

SDL Support: I am not trying to translate the document properties.


Direct link Reply with quote
 

SDL Community  Identity Verified
United Kingdom
Local time: 09:16
English
Displaying all formatting tags? Oct 22, 2012

johnyaku wrote:

The problem is that the formatting becomes totally whacko.

For example, in the original document the content of the {REF} fields was in plain text (no bold, italic, etc.) But when I update the references in Word using F9 the first word of the content is in plain text, but the second and subsequent words are in bold. There are also issues with the fonts and font sizes, as described previously.



Hi,

Perhaps you are not displaying all the formatting tags and as a result not placing them back into the target document? Sorry if this is an obvious question for you... it's hard to guess what might be happening here without good examples to look at. Just in case you don't know about this press ctrl+shift+h when you are in a segment that is changing like this and see if this introduces tags you should be taking over to the target from the source.

If you can share an example that behaves like this it would also be helpful to see it?

Regards

Paul


Direct link Reply with quote
 

johnyaku  Identity Verified
Local time: 19:16
Japanese to English
TOPIC STARTER
Specific example Oct 24, 2012

Yes, I am displaying all formatting tags, and I have changed the Display Filter to show all content, including formatting tags external to the segments, but I am still no wiser about what is going on.

I have just completed translating the second document in this series, which suffers from the same problem.

Here are the full details of one specific example.

There is a bookmarked section heading called "Network Configuration", and several {REF} fields pointing to that bookmark.

First I will describe the formatting associated with the bookmarked section heading.

The "Network Configuration" segment does not contain any internal formatting tags.

Immediately /before/ the "Network Configuration" segment (but external to the segment) there are the following tags:

‹bookmarkstart name="_Ref1"/› ‹bookmarkstart name="_Ref2"/›‹bookmarkstart name="_Toc1"/›
‹csf style="Heading 2,H2" bulleted="yes" heading="2" font="Times New Roman" bold="on" size="12"›
‹cf font="Arial"›

Immediately /after/ the "Network Configuration" segment (but external to the segment) there are the closing tags matching the tags above:

‹bookmarkend name="_Ref1"/› ‹bookmarkend name="_Ref2"/>‹bookmarkend name="_Toc1"/›
‹/cf›‹/csf›

I am not sure why there are three bookmarks for this item, I guess the person who created the original document created a new bookmark every time they created a new reference.

Turning now to the tags associated with one of the references to the "Network Configuration" segment.

The segment itself is as follows:

‹field id="1" value="2.2"›, ‹field id="2" value="ネットワーク構成"›

Here "2.2" is the section number, and "ネットワーク構成" means "Network Configuration" in Japanese.

Before the segment (but external to the segment), there are the following formatting tags:

‹csf style="Normal" font="Times New Roman" size="12"›‹cf font="Arial" size="9"›

After the segment there are the closing tags matching these tags: ‹/cf›‹/csf›

OK, now I will describe what happens when I generate the target translation document.

Initially, immediately after the target translation document has been generated, the values of the {REF} fields are still displayed in Japanese, as follows:

2.2, ネットワーク構成

The "2.2," uses 9pt Arial font, while the ネットワーク構成 uses 9pt SimSun font (the same as the original).

After I select all text and press F9 to update all references, the content of {REF} field is displayed as follows:

2.2, Network Configuration

The "2.2," is still in 9pt Arial font, but the "Network" is in 9pt Times New Roman and the "Configuration" is in 14pt bold Arial. The style for both "2.2," and "Network" is "Normal", but the style for "Configuration" is "Heading2, H2").

The heading itself is displayed in 12 pt bold Arial.

I don't understand where the 14pt came from, and I don't understand why the formatting changes midway through the content of the {REF} field.

As an experiment, I deleted the ‹csf› fields around both the bookmarked item and the reference (it is a bit of a mystery to me where they came from in the first place). The result was that "Network Configuration" was displayed in 12pt Arial with no bold and "Normal" style. Apart from the font size, this is what I was aiming for.

I suspect that it would be more work to remove all the ‹csf› fields than to simply reformt the resulting Word file. But looking closely, I see that almost all of the segments in this document are enclosed by‹csf style="Normal" font="Times New Roman" size="12"›‹/csf› tags, even though Times New Roman is not used anywhere in the document. In every (?) case these ‹csf› tags are overriden by a ‹cf› tag that changes the font back to Arial (and usually changes the font size).

This seems quite strange to me. Are these ‹csf› tags generated by SDL Studio? Can their generation be suppressed or customized?




[Edited at 2012-10-24 06:24 GMT]

[Edited at 2012-10-25 22:07 GMT]


Direct link Reply with quote
 

SDL Community  Identity Verified
United Kingdom
Local time: 09:16
English
Too hard... Oct 24, 2012

... with this much detail for me to reproduce anything. If you really want help with this please provide a document that behaves in this way so I can test... and then I'm very happy to help figure out what's happening.

You can email me at pfilkin@sdl.com

Regards

Paul


Direct link Reply with quote
 


To report site rules violations or get help, contact a site moderator:


You can also contact site staff by submitting a support request »

Handling MS Word {REF} fields in SDL Studio 2011

Advanced search







BaccS – Business Accounting Software
Modern desktop project management for freelance translators

BaccS makes it easy for translators to manage their projects, schedule tasks, create invoices, and view highly customizable reports. User-friendly, ProZ.com integration, community-driven development – a few reasons BaccS is trusted by translators!

More info »
SDL Trados Studio 2017 Freelance
The leading translation software used by over 250,000 translators.

SDL Trados Studio 2017 helps translators increase translation productivity whilst ensuring quality. Combining translation memory, terminology management and machine translation in one simple and easy-to-use environment.

More info »



Forums
  • All of ProZ.com
  • Term search
  • Jobs
  • Forums
  • Multiple search