Macro that performs Paste Special > Paste as unformatted text - can you help?
Thread poster: ViktoriaG

ViktoriaG  Identity Verified
Canada
Local time: 18:37
English to French
+ ...
Mar 27, 2008

Right now, I am editing a translation of medium quality - it is not that bad, but the terminology is a bit obscure and not consistent. I have loaded my own TM for the same client (a TM the units of which I created; these are units that come from the same collection of documents that I am editing right now) in SDL Workbench, and loaded the TM containing the units I need to edit (units created by other translators; these are the exact segments found in the document I am editing) in the Concordance window. To work faster, if there is no match for the open segment in workbench (my TM), I copy the match in the Concordance window (the other translators' TM), paste it in Word and apply some corrections.

My problem is that every time I copy a match from the Concordance window and paste it as the target segment in Word, even though I did set Word up to automatically format the pasted string to fit with the string that is already in the document (which would be the same as pasting the string as unformatted text), the font changes. So, the only way I can paste these strings is to click on Edit, then click on Paste special, then click on Unformatted text, then click OK. Considering that I perform this operation for nearly every single segment, it is taking a lot of time.

I would need to know if there is a macro I can use for this, one that would replace the "click on Edit, then click on Paste special, then click on Unformatted text, then click OK" operation. I have no knowledge of macros, so if somebody here replies with a solution, please also explain how I can implement the macro and how to use it.

Thanks in advance!

Edit: I am using Word XP.

[Edited at 2008-03-27 19:08]


Direct link Reply with quote
 
Boyan Brezinsky  Identity Verified
Bulgaria
Local time: 01:37
English to Bulgarian
+ ...
Here it is Mar 27, 2008

The article is a little wordy, but describes and explains everything perfectly:
https://pubs.logicalexpressions.com/Pub0009/LPMArticle.asp?ID=128


Direct link Reply with quote
 

Riccardo Schiaffino  Identity Verified
United States
Local time: 16:37
Member (2003)
English to Italian
+ ...
Paste Clean Mar 27, 2008

Hi Victoria:

The Word Tips site has the exact solution for this problem; see the following article:

Paste Clean

Riccardo


Direct link Reply with quote
 

ViktoriaG  Identity Verified
Canada
Local time: 18:37
English to French
+ ...
TOPIC STARTER
Good stuff! Mar 27, 2008

Great! It seems I am not the only one who finds this feature cumbersome. Thanks, Riccardo!

It seems the code would be this:


Sub PasteClean()
Selection.PasteSpecial Link:=False, _
DataType:=wdPasteText, _
Placement:= wdInLine, _
DisplayAsIcon:=False
End Sub


Now, I just need to know what I have to do with this code and then how I can use it. Can you give me some clues? I know it is really easy and simple, but every time I look up macro subjects, the authors seem to assume I already know the basics of marcos - this was also Allen Wyatt's case - when I really don't. Please, enlighten me.

Thanks!


Direct link Reply with quote
 

Alexey Ivanov  Identity Verified
Russian Federation
Local time: 01:37
English to Russian
An alternative solution Mar 27, 2008

Victoria,

If you don't find a macro, you can try a free TMX Memory editor Olifant which I use for exactly this purpose. I actually find it much more handy than using the Concordance in Trados TWB. It does not create any font problems at all. To use it you have to export the TM into the TMX format first. Then you open it with Olifant and then, using search tool you will find the required string. And finally, using "copy and paste" you import the target into your translation. Here's the link:
http://www.translate.com/technology/tools/Olifant.html

It also has many more uses. Such as swapping the languages, editing source and target, deleting the inner code which is very useful for getting rid of the TagEditor tags, and more, all of which I don't know.

Good luck.


Direct link Reply with quote
 

ViktoriaG  Identity Verified
Canada
Local time: 18:37
English to French
+ ...
TOPIC STARTER
Thanks for all your suggestions Mar 27, 2008

Thanks a bunch - all your suggestions, although they are very different from each other, are convenient solutions to the problem. Without even realizing it, we just created a mini-guide on Paste special, which I hope will be useful to the rest of the community.

Alexey's solution can be interesting, and I actually use this approach in other applications, except that I have switched from Olifant to ApSic XBench a while ago. However, I don't find it as useful as using a macro in this specific case, because I would have to toggle Word and Olifant/XBench to do this, which is a bit of a problem. The reason why it is not ideal in this particular case is that I want to give privilege to my own matches in my Workbench TM but also be notified of the reference TM matches without having to switch windows. If I used Olifant/XBench, I would have to copy the string from my open source segment, toggle to Olifant/XBench and paste the string and hit Enter. Then, I would have to copy the result, switch back to Word and Ctrl+V. This also takes time, and I believe a macro can be faster. But I agree, Alexey - Olifant is an excellent tool and there is much more to it than meets the eye. If you haven't yet, be sure to check out ApSic XBench - it is similar, but has other features Olifant doesn't have. They are both very useful tools.

bsb_2, thank you so much for the link! I now have a shiny new Alt+Ctrl+V shortcut that does exactly what I wanted! The guide may be wordy, but for a total macro analphabet like me, it might as well. I found it very useful and will recommend it to all. Thanks to Riccardo also - I ultimately used a different macro solution, but it will definitely be useful to people searching the forum.

We all win!

[Edited at 2008-03-27 21:02]


Direct link Reply with quote
 

Giles Watson  Identity Verified
Italy
Local time: 00:37
Italian to English
Paste Special Mar 27, 2008

Hi Viktoria,

I use Paste Special a lot, too, and in fact the button already exists.

Click the Word toolbar with the right mouse button, click Customize and then drag Paste Special from the Edit menu onto the toolbar.

The button isn't associated with an icon by default so you'll have to select one yourself.

HTH

Giles



[Edited at 2008-03-27 21:25]


Direct link Reply with quote
 

Heinrich Pesch  Identity Verified
Finland
Local time: 01:37
Member (2003)
Finnish to German
+ ...
You can record own macros Mar 28, 2008

Select Tools-Macros-New Macro, then assign a key-shortcut for it and click on Record. A small icon appears. Now you do what you have to do with the mouse, when you are ready you click the Stop-icon and you are done and can perform the macro using the keyboard shortcut you have assigned to it (e.g. alt+cntrl+m).
The same procedure for Excel. In excel I mostly use past special values only to get red of the formulas when doing my bookkeeping.
Regards
Heinrich


Direct link Reply with quote
 

ViktoriaG  Identity Verified
Canada
Local time: 18:37
English to French
+ ...
TOPIC STARTER
Thanks, Giles and Heinrich Mar 28, 2008

Your contributions are valuable. Giles' solution is about halfway what I wanted. I did not know that I could put such a button on my toolbar. It's good to know we can do that, not just with the Paste special function but with other stuff, too. However, that would only be half the solution - it does not include the Unformatted text command. So, I went with creating a macro instead, one that does the entire process from start to finish with just a keyboard shortcut.

Heinrich's solution is also good, but it isn't perfect, because if you simply record the macro that way, it doesn't work fully. See the link provided by bsb_2 - it doesn't explain why that method alone doesn't work perfectly, but it does provide the solution to it. It seems that after recording the macro the way Heinrich suggests, it still needs to be edited in VBA. That is, by recording the macro alone, the solution is incomplete, and you have to manually edit it for it to do exactly what I wanted.

Thanks for caring!


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 »

Macro that performs Paste Special > Paste as unformatted text - can you help?

Advanced search






Across v6.3
Translation Toolkit and Sales Potential under One Roof

Apart from features that enable you to translate more efficiently, the new Across Translator Edition v6.3 comprises your crossMarket membership. The new online network for Across users assists you in exploring new sales potential and generating revenue.

More info »
Anycount & Translation Office 3000
Translation Office 3000

Translation Office 3000 is an advanced accounting tool for freelance translators and small agencies. TO3000 easily and seamlessly integrates with the business life of professional freelance translators.

More info »



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