How to collect stories with PageMaker for Mac (and PC too) without Trados Story Collector

translation_articles_icon

ProZ.com Translation Article Knowledgebase

Articles about translation and interpreting
Article Categories
Search Articles


Advanced Search
About the Articles Knowledgebase
ProZ.com has created this section with the goals of:

Further enabling knowledge sharing among professionals
Providing resources for the education of clients and translators
Offering an additional channel for promotion of ProZ.com members (as authors)

We invite your participation and feedback concerning this new resource.

More info and discussion >

Article Options
Your Favorite Articles
You Recently Viewed...
Recommended Articles
  1. ProZ.com overview and action plan (#1 of 8): Sourcing (ie. jobs / directory)
  2. Réalité de la traduction automatique en 2014
  3. Getting the most out of ProZ.com: A guide for translators and interpreters
  4. Does Juliet's Rose, by Any Other Name, Smell as Sweet?
  5. The difference between editing and proofreading
No recommended articles found.

 »  Articles Overview  »  Technology  »  Software and the Internet  »  How to collect stories with PageMaker for Mac (and PC too) without Trados Story Collector

How to collect stories with PageMaker for Mac (and PC too) without Trados Story Collector

By arterm | Published  04/29/2004 | Software and the Internet | Recommendation:RateSecARateSecARateSecARateSecARateSecI
Contact the author
Quicklink: http://files.proz.com/doc/22
Author:
arterm
Serbia
English to Russian translator
 
View all articles by arterm

See this author's ProZ.com profile
How to collect stories with PageMaker for Mac (and PC too) without Trados Story Collector
How to collect stories with PageMaker for Mac (and PC too) without Trados Story Collector

Once upon a time, your client can ask you to translate a large PageMaker file in Trados and layout it back to PageMaker publication. This trivial in general task becomes much more challenging when you have to deliver and process Mac files. Obviously, Trados story collector will not work with Mac. Converting the file to PC and then back may be also difficult. For instance, it is very hard for Cyrillic files and may also pose problems to other languages.

Among all, one of the reasons to create a custom story collector is that Trados Story Collector is Far from ideal.

So what is the solution for the above task?
There is one and it is PageMaker Scripting language. This powerful toy lets one create one’s own Cross-Platform Story Collector!

Please note that scripts given in this small article can be used at your own risk and the author does not take any responsibility for these scripts. So please understand the process before using the scripts. You can modify and enhance these scripts freely.

So let us formulate a smaller task first. Translating PageMaker files is easy with tagged text. Exporting frames to tagged text can be dramatically simplified using the PageMaker Scripting language. Below I summarized basic steps to create the selected story export and import script:

1) Display the Scripts palette in PageMaker (Window -> Plug-in Palletes->Show Scripts)
2) Create the new empty script with the name “Export selected story”
3) Place the following code in the new script (please note the dots and commas, they are necessary):

GetPubName >> PubName
GetPageNumbers >> nStartPage, nNumPages, ..., ..., ...
GetPageNumber >> pagenum, ...
GetPageNumber >> pageNumber, ...
GetPageID pageNumber >> pageNumTemp
pageID = pageNumTemp
GetSelectIDList >> NumOfObjects, objectlist
if NumOfObjects < 100
loop x = 1, NumOfObjects
set objectlist >> nObjectID, ..., ..., ..., cTypeOfObject, ..., ..., ..., ..., ..., ..., ..., ..., ..., ..., objectlist
if cTypeOfObject = 1
fileName = quote(pageNumber)+"."+quote(pageID) + quote(nObjectID)
textFileName = PubName+fileName + "k.s.txt"
SelectID nObjectID
TextEdit
export textFileName, "Tagged Text", false
endif
endloop
endif

4) Select with the Black arrow cursor the story to export and run the above script. The script will not run if you use a text tool to enter into the story. It must be selected as an object.
5) Run the script named “Export selected story”
6) Now you should have a Tagged text file in the same folder as your publication. The file will have a coded name that links it to the source publication and story, do not change it. Otherwise, Import Script will not work
7) TRANSLATE THE TEXT WITH TRADOS, WORDFAST, OR ANY OTHER TOOL THAT ALLOWS TRANSLATION OF PAGEMAKER TAGGED TEXT FILES. PLACE THE TRANSLATED FILE INTO THE SAME DIRECTORY WITH THE SAME NAME AS THE ORIGINAL. See separate article about issues of translating Mac PageMaker tagged text file on PC and their resolution.
8) Create the new empty script with the name “Import selected story”
9) Place the following code in the new script (please note the dots and commas, they are necessary):

GetPubName >> PubName
GetPageNumbers >> nStartPage, nNumPages, ..., ..., ...
GetPageNumber >> pagenum, ...
GetPageNumber >> pageNumber, ...
GetPageID pageNumber >> pageNumTemp
pageID = pageNumTemp
GetSelectIDList >> NumOfObjects, objectlist
if NumOfObjects < 100
loop x = 1, NumOfObjects
set objectlist >> nObjectID, ..., ..., ..., cTypeOfObject, ..., ..., ..., ..., ..., ..., ..., ..., ..., ..., objectlist
if cTypeOfObject = 1
fileName = quote(pageNumber)+"."+quote(pageID) + quote(nObjectID)
textFileName = PubName+fileName + "k.s.txt"
SelectID nObjectID
TextEdit
import textFileName, replaceentire
endif
endloop
endif

10) Select with the Black arrow cursor the story to be imported after translation of the tagged text and run the above script. The script will not run if you use a text tool to enter into the story. It must be selected as an object.
11) Run the script called “Import selected story”
12) Translated tagged file of the selected story will be imported into the selected story.

Making a complete Story Collector.
This is a bit longer story but in brief, it is quite simple:

1) Duplicate the above scripts with different names
2) Add a loop to cycle through pages
3) Please note that PC PageMaker (BUT NOT MAC) has some memory overflow issues and sometimes can stop exporting stories at the middle of publication if there are more than 50 stories or so on a page.
4) All information about loops and other PageMaker script features can be found in the file named ScriptGuide.pdf that is located in the folder named “Techinfo” of your PageMaker installation.
5) Above scripts should run both on PageMaker 6.x and 7.x
6) If you want to have a ready-to-use script that exports and imports back all stories in the PM publication contact me at my proz.com profile. (The script works reliably mainly on Mac or with smaller PC publications)

Have a nice day
Arterm Sedov


Copyright © ProZ.com, 1999-2024. All rights reserved.
Comments on this article

Knowledgebase Contributions Related to this Article
  • No contributions found.
     
Want to contribute to the article knowledgebase? Join ProZ.com.


Articles are copyright © ProZ.com, 1999-2024, except where otherwise indicated. All rights reserved.
Content may not be republished without the consent of ProZ.com.