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

Convert Word Document to indesign file with InDesign Server

Community Beginner ,
Feb 02, 2017 Feb 02, 2017

Copy link to clipboard

Copied

Hello.

1. I'm using InDesign server not the simple InDesign application.

2. Documentation says that the functions of server and the application are identical.

3. I've found that as server as application can import Microsoft Word files (according to ansvers for CS2 server).

4.I can not find any examples of import in the adobe scripting guides.

5. The java script fragment

     app.open(File("....doc"))

    does not work for doc files.

6. There are a lot of proposials to convert word to pdf at first with another tools - it is unacceptable for me.

So, could you please appoint to the exact script fragment for the importing Microsoft Word documents?

Thanks.

-Alex.

TOPICS
Scripting

Views

4.9K

Translate

Translate

Report

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

People's Champ , Feb 02, 2017 Feb 02, 2017

In InDesign, one "places" Word documents, rather than open. So try using the place() method of an insertionPoint (or any Text object):

InsertionPoint.place (fileName: File , showingOptions: Boolean , withProperties: Object ):Array of varies

Adobe InDesign CC 2015 (11.0) Object Model

Places the file.

fileName: Data Type: File

The file to place

showingOptions (optional): Data Type: Boolean , Default Value: false

Whether to display the import options dialog (Optional)

withProperties: Data Type: Object

...

Votes

Translate

Translate
People's Champ ,
Feb 02, 2017 Feb 02, 2017

Copy link to clipboard

Copied

In InDesign, one "places" Word documents, rather than open. So try using the place() method of an insertionPoint (or any Text object):

InsertionPoint.place (fileName: File , showingOptions: Boolean , withProperties: Object ):Array of varies

Adobe InDesign CC 2015 (11.0) Object Model

Places the file.

fileName: Data Type: File

The file to place

showingOptions (optional): Data Type: Boolean , Default Value: false

Whether to display the import options dialog (Optional)

withProperties: Data Type: Object

Initial values for properties of the placed object(s) (Optional)

Ariel

Votes

Translate

Translate

Report

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
Community Beginner ,
Feb 02, 2017 Feb 02, 2017

Copy link to clipboard

Copied

Thanks a lot for a detailed answer.

I just would like to specify a couple items:

-Does it means that I can place the word document into .indd file and print it as a pdf, for example?

-Should I perform some additional processing of placed word document to place it into .indd?

-Otherwize could you please appoint the sequence of basic steps to implement word->indd convertion?

Thanks.

-Alex

Votes

Translate

Translate

Report

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
People's Champ ,
Feb 03, 2017 Feb 03, 2017

Copy link to clipboard

Copied

Hi Alex,

You can indeed place a Word document into an InDesign file and print it as a PDF. But when the Word document comes into InDesign, expect a lot of work tidying up the formatting, redesigning, and preparing the file for the correct sort of PDF (digital or print) that is required. This is a big job usually (unless you're lucky with your Word file, or it's very simple, or you really don't care what it looks like much) -- and many people have full-time jobs, if not careers, doing just that all day 🙂

"-Should I perform some additional processing of placed word document to place it into .indd?"

Are you talking about from a scripting perspective? From a scripting perspective, you do not have to do anything special to a Word file to be able to place it into InDesign. (But from a practical point of view, people usually do prepare Word files before placing, to make it easy to work with them afterwords in InDesign.)

"-Otherwize could you please appoint the sequence of basic steps to implement word->indd convertion?"

InDesign, place your text cursor in a text frame somewhere. Then run this one-line script:

app.selection[0].place("C:\\MyFile.doc");

That's the basics.

Ariel

PS It sounds to me like you need to get a little more familiar with using InDesign. For scripting, it's always good to know first how to do something in InDesign with the regular UI before trying to script it, because scripting really basically just replicates the steps you would be doing manually as a user.

Votes

Translate

Translate

Report

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
Community Beginner ,
Feb 04, 2017 Feb 04, 2017

Copy link to clipboard

Copied

Thanks, Ariel.

I've made the doc placing in the regular UI.

It seems it requiers manual page-by-page frames filling.

The place() method itself has an autoflow flag that should lead to some kind of autoadding/autofilling frames.

At the first glance It could be queit simple in case if we can get word document page amount before the placing.

The another common way is spreading the content of doc with cycling with text frames adding and overflow checking.

Thanks.

-Alex

Votes

Translate

Translate

Report

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
People's Champ ,
Feb 05, 2017 Feb 05, 2017

Copy link to clipboard

Copied

I've got a blog post that shows a very simple implementation of creating and linking new text frames until all the text is visible here:

https://www.id-extras.com/multi-file-auto-place

Votes

Translate

Translate

Report

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
Community Expert ,
Feb 05, 2017 Feb 05, 2017

Copy link to clipboard

Copied

LATEST

alexanderk57613459 wrote:

… The place() method itself has an autoflow flag that should lead to some kind of autoadding/autofilling frames. …

Hi Alex,

now reading that thread here, that is related to the other one you started, I could see a potential problem with your thinking.

Generally spoken, method place() itself has no autoflow flag. Only when it's used with the Page object.

See my reply here:

Re: Place all Microsoft Word pages in the .indd document

Regards,
Uwe

Votes

Translate

Translate

Report

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