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

cannot establish COM Application object "InDesign.Application.CS6"

New Here ,
Oct 22, 2014 Oct 22, 2014

Copy link to clipboard

Copied

I run VBA scripts in Microsoft Excel 2010 that communicate with InDesign via COM Interface.

I did that successfully using InDesign CS4 and CS5, but with CS6 the Connection from Excel to the InDesign Application does not establish. The lines:

Dim InApp As InDesign.Application

Set InApp = CreateObject("InDesign.Application.CS6")

result in "error 13 type mismatch"

I checked the following

  • reference to the tlb file is correct
  • when typing commands in Excel VBA editor, IntelliSense Shows all the methods and properties, so the library must be present
  • When InDesign CS6 is not running, it will start up, then the error Shows up
  • The line "CreateObject("InDesign.Application.CS6")" runs without error, I just cannot assign the object returned to the variable

What to do?

TOPICS
Scripting

Views

1.1K

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

Community Beginner , Oct 23, 2014 Oct 23, 2014

Seem to have some answer...

go to this directory:

C:\ProgramData\Adobe\InDesign\Version 7.0\en_US\Scripting Support\7.0 (or where ever .tlb file is present)

And DELETE (or rename) the file "Resources for Visual Basic.tlb"

Launch InDesign by right-clicking and choosing "Run as Administrator".

This allows InDesign to make appropriate changes to the registry and who knows what else in the system.

You can then quit InDesign and launch it normally (I don't like running things as Admin as a rule).

Try your

...

Votes

Translate

Translate
Community Beginner ,
Oct 23, 2014 Oct 23, 2014

Copy link to clipboard

Copied

This is the same problem, I face, as well. I am also, looking for a solution, for this issue.

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 ,
Oct 23, 2014 Oct 23, 2014

Copy link to clipboard

Copied

Seem to have some answer...

go to this directory:

C:\ProgramData\Adobe\InDesign\Version 7.0\en_US\Scripting Support\7.0 (or where ever .tlb file is present)

And DELETE (or rename) the file "Resources for Visual Basic.tlb"

Launch InDesign by right-clicking and choosing "Run as Administrator".

This allows InDesign to make appropriate changes to the registry and who knows what else in the system.

You can then quit InDesign and launch it normally (I don't like running things as Admin as a rule).

Try your script.

I got this from https://forums.adobe.com/thread/834780

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
New Here ,
Oct 23, 2014 Oct 23, 2014

Copy link to clipboard

Copied

Indeed this is the solution, valid for Indesign CS5 and CS6.

I might add that the connection does not establish when Indesign runs in admin mode. It MUST be reopened in normal mode after the tlb file is beeing rebuilt (or whatever happens there).

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
New Here ,
Feb 04, 2017 Feb 04, 2017

Copy link to clipboard

Copied

LATEST

Hi Guys, not sure if this thread is dead, but I'm having a similar issue with Indesign 11.0/2015 and 12.0/2017 on two different systems, one Windows 10 and one Windows 7 SP2 (64)

The COM interface for Photoshop works perfectly, scripting away in Python, but InDesign is missing by default it seems.

Tried regtlibv12.exe on Windows 7, claims to successfully register, but says it has no property '_Application'.

Tried tlbimp.exe on Windows 10, says the interface isn't derived from IUnknown, so it skips it.

I'm trying to string some scripts together through Python with the comtypes lib, the dream was so close!

It launches InDesign but alas doesn't get the interface hooks in.

I've renamed the 'Resources for Visual Basic.dll' and regenerated it as Admin a couple of times. No joy there.

Also reinstalled a few times as admin to check. Still no joy.

It's the COM interface that was never meant to be I feel...

Any help appreciated!

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