Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

[JS, CS3] a script to change language in all paragraph styles

New Here ,
Jul 09, 2009 Jul 09, 2009

Hi,

I made a script to change the language in all paragraph styles to "French", but when I run it I get the error: "Invalid request on root style". Could you please tell me what am I missing?

myDoc = app.activeDocument;
myStyles = myDoc.paragraphStyles;
for (i = 0; i < myStyles.length; i++)
{
myStyle = myStyles;
myStyle.appliedLanguage = "French";
}

TOPICS
Scripting
1.1K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Jul 09, 2009 Jul 09, 2009

Parargaph Style #0 is [No Style], and you cannot change it this way. Simply start your loop at 1.

Style #1 is [Basic Style], and if you have trouble changing that as well, just start at 2.

Translate
Community Expert ,
Jul 09, 2009 Jul 09, 2009

Parargaph Style #0 is [No Style], and you cannot change it this way. Simply start your loop at 1.

Style #1 is [Basic Style], and if you have trouble changing that as well, just start at 2.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 09, 2009 Jul 09, 2009
LATEST

Thanks a lot!

The problem is solved

Ola

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines