Copy link to clipboard
Copied
Hello,
I have to build quite a few text layers in a larger project.
This project has to be localized in 12 other languages.
Is there a way to export the textlayers to a .doc,.xls, .csv or similar fileformat for the translators which I then can re-import into my project so the language in the original layers is replaced while maintaining the position and keyframes etc.?
Any help is very appreciated, since I am not looking forward to a copy and paste orgy....
Copy link to clipboard
Copied
I showed how to import text from a text document as well as writing text documents in episodes 16 and 17 of my After Effects ExtendScript training. They might help you.
http://provideocoalition.com/pvcexclusive/video/after-effects-extendscript-training-ep-16
http://provideocoalition.com/pvcexclusive/video/after-effects-extendscript-training-ep-17
Copy link to clipboard
Copied
Hi David,
thank you very much.
Is there a chance to download the script from your side?
Though I'm quite interested in all the details I'd just like to test the script for now quite swiftly. A colleague of mine who is far more script savy than I am could probably make some necessary alterations.
Copy link to clipboard
Copied
Another thing I came across.
I tried your other tutorial here:
http://provideocoalition.com/pvcexclusive/story/expression_shorts_-_read_external_text_document
I copied the source code and adjusted the path (whcih works, I had it checked)
try{
myPath = "C:\\TEST\\01_Intro.txt";
$.evalFile(myPath);
eval(thisComp.name)[0];
}
catch(err)
{
err;
}
But I get an error message like this:
SyntaxError: Expected: ;
We tried this instead:
try{
myPath = "C:\\TEST\\01_Intro.txt";
$.evalFile(myPath);
//eval('' + thisComp.name + '[0];');
DE_Intro_fein[1];
}catch(err){
err;
};
And it worked. But If I don't want to hardcode (is this the right expression?) I need your code to be working.
Do you have any advice?
Thank you.
Copy link to clipboard
Copied
I managed to do it with this tutorial (and it works now)
http://provideocoalition.com/pvcexclusive/story/expression_shorts_-_re ad_external_text_document
But I still have one concern:
When the translators have to use special characters like ö or ñ etc., is there anything I have to tell them or bear in mind when briefing them how to handle the txt file?
Thank you again for your help.
Copy link to clipboard
Copied
As far as I know that should be fine. My guess though is if any of those special characters exist only in a certain font, that you also have the same font. Otherwise the only special characters that I'm aware of that need special care are these:
Copy link to clipboard
Copied
Hmmm, unfortunately my Greel translation produces only syntax errors. Do you have an idea to solve this?
I already asked some colleagues but they don't have any idea, either.
Thanks
Copy link to clipboard
Copied
Can you show what is inside C:\\TEST\\01_Intro.txt
Make sure your script file itself, and the external files, are all saved in UTF-8 format. You can use a standard text editor--like Sublime--to ensure that it is. Are you sure that the syntax errors that are thrown are a result of you reading an external text file with UTF-8 characters?
Typically if you're going to read an external file for data, you'll wants to use File.open('r'). Check the documentation on the File object. $.evalFile is generally used when you want to read another script file, not a file that contains data.