In case anybody still needs it, here's how you can use Adobe InDesign CS3 from .Net code:
1. Locate Resources for Visual Basic.tlb in C:\Documents and Settings\All Users\Application Data\Adobe\InDesign\Version 5.0\Scripting Support\5.0 folder.
2. Open command prompt and execute:
Code:
TlbImp.exe "Resources for Visual Basic.tlb" /out:Interop.InDesign.dll
TlbImp.exe is located in C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\Bin folder on my machine. This will generate Interop.InDesign.dll file. This is an interop assembly.
3. Add reference to Interop.InDesign.dll to your project.
4. Use this code to create application object:
Code:
Type type = Type.GetTypeFromProgID("InDesign.Application.CS3");
if (type == null)
{
throw new Exception("Adobe InDesign CS3 is not installed");
}
InDesign._Application app = (InDesign._Application)Activator.CreateInstance(type);
--
Please visit my blog at
http://chuchuva.com/pavel/