This content has been marked as final. Show 2 replies
Have you taken a look at the InDesign CS3 Scripting Guide: VBScript? Or the associated scripts? (Both are available at the InDesign Scripting Home Page listed at the top of this forum.) Or at any of the VBScript samples that are installed with InDesign CS3? I'm pretty sure you can find what you need in one or more of those.
But the quick answer to your question requires another question--how do you know which image you want to refer to? If you want to get at it by its file name, then it's best to approach it via the Document.Links collection. If you want to find it in a specific place in the layout, you'd get a reference to the page or spread (as you've already done) and then iterate through the page items on the page until you find the one that meets the criteria you're searching for. You might take a look at the SelectItems.vbs script to see the basics of how to do this.
thank you so much for your reply. I started thinking that there was nobody out there at all.
Yes, I have gone through several VBScript samples which is how I found out the code I stated in my original request. However, all the other listed lines in those examples produce error codes like:
'This statement not supported... '. I have tried several options.
There ought to be some sort of type library which I can not find.
All the applications like Word etc. have there own way of addressing
items when using the OLE-container.
All I need is actually something to start with for one picture frame
and one text frame underneath. One picture should be loaded from a file into the picture frame. At the this time, it would be enough if I could experiment with an item number. But any other method would be good as well.
I must go on with the project and would be really grateful if
there were some solutions.
Thank you so much,