• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Word script
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Word script


  • Subject: Re: Word script
  • From: "Stockly, Ed" <email@hidden>
  • Date: Tue, 23 Aug 2016 18:33:57 +0000
  • Thread-topic: Word script

Here's a quick and dirty version that gives you an idea as to how to
approach this.


tell application "Microsoft Word"
  tell document 1
    set the style of every paragraph to "Normal"
    set the style of every character to "normal"
  end tell
end tell


This changes both the paragraph styles and the character styles.

You need to use the exact name of the style (not sure if it's case
sensitive). If you're not sure what the style names are you can run this
script to get a list (it's usually pretty long, because, you know, it's
Word).

tell application "Microsoft Word"
  activate
  tell document 1
    return name local of every Word style
  end tell
end tell


 HTH

ES





On 8/22/16, 7:01 PM,
"applescript-users-bounces+ed.stockly=email@hidden on
behalf of BC"
<applescript-users-bounces+ed.stockly=email@hidden on
behalf of email@hidden> wrote:

>I want to pass a batch of text documents (opened in Automator with the
>"Open Word Documents" action) to the script which would in turn tell
>Microsoft Word (2008) to set the style of the text in the documents to
>Normal.
>
>In Word, there is a command called "NormalStyle" which can be assigned a
>keyboard shortcut. But how can I get Applescript to recognize it, as well
>as apply it to several documents at the same time?
>


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden


References: 
 >Word script (From: BC <email@hidden>)

  • Prev by Date: [ANN] ModuleLoader 3.0
  • Next by Date: Unwanted output
  • Previous by thread: Re: Word script
  • Next by thread: [ANN] ModuleLoader 3.0
  • Index(es):
    • Date
    • Thread