🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: adobe.scripting.indesign
Article #19759

Re: VB6&ID - Replace function like ImportXML

#19759
From: David Ames
Date: Thu, 21 Nov 2002 03:49
22 lines
2473 bytes
Yep, it's a quark Import... We are looking at switching our Mac/Quark/AppleScript proofing department to PC/ID/VBScript... (Shane Stanly actualy setup our AppleScript proofing stuff - Hey Shane!!!)... 

Anyway - back on topic... There is a enum of idUnassigned for ContentType (value = 1970168179), so I would hope that ID returned idUnassinged instead of an exeption, but anyway, i think that error trapping for it is the only work around... I'm also finding there are a lot of little quirks with IDScripting, mainly to do with assigning certain variables to certain objects, but these are also work-aroundable... 

EG: 
Dim idPageItem As Indesign.PageItem 
.... 
Set idPageItem = idPage.PageItems(curPageItem) fails with Type mismatch 

What is your opinion of the stability of ID 2 as a serious graphic scripting platform? - Would you wait for ID3 before moving it into a production enviroment? 

Next Question :) I'm doing my image replacement by iterating through the collection of PageItems in the Document.Pages object. If ContentType = idGraphic then relink the idImage.Link... Easy... 

BUT, I can't use a similar method to access the idTextFrames object... 

EG: 
  ElseIf idPage.PageItems(curPageItem).ContentType = idText Then 
msgbox(idPage.PageItems(curPageItem).count) 

will fail with Object doesn't support this property or method. In fact every attempt to access the TextFrames object of the PageItems object will fail with the same error... But I can do text replacement by iterating through the TextFrames object of the Page object. - once again, workaroundable, but it means we are looping through the document twice instead of once.... 

P.S. Thanks for all of your help!!! Much appriciated...
Technical Details
Message-ID: <1de6b092.3@WebX.la2eafNXanI>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-05!sn-xit-01!sn-xit-08!supernews.com!newsfeed.news2me.com!newsfeed.media.kyoto-u.ac.jp!newsfeed01.sul.t-online.de!t-online.de!WebX
References: <1de6b092.-1@WebX.la2eafNXanI>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f939a,9fb81744ad733cf6
X-Google-Attributes: gidf939a,public
X-Google-ArrivalTime: 2002-11-20 20:07:38 PST
From: "David Ames" <davida@in-site.com.au>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-05!sn-xit-01!sn-xit-08!supernews.com!newsfeed.news2me.com!newsfeed.media.kyoto-u.ac.jp!newsfeed01.sul.t-online.de!t-online.de!WebX
Newsgroups: adobe.scripting.indesign
Subject: Re: VB6&ID - Replace function like ImportXML
Message-ID: <1de6b092.3@WebX.la2eafNXanI>
Date: Wed, 20 Nov 2002 19:49:07 -0800
References: <1de6b092.-1@WebX.la2eafNXanI>
Lines: 39
MIME-Version: 1.0
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit