Article View: adobe.scripting.indesign
Article #20026Re: character styles to XML Tags?
From: laurent Battistelli
Date: Wed, 13 Nov 2002 15:31
Date: Wed, 13 Nov 2002 15:31
49 lines
2467 bytes
2467 bytes
I know that is possible in VB but in fact you have to make it !!!
there is no function available which do it automatically like for a
paragrapg style where you can map tag with parastyle
so you have to go through all your XML file and when you have a specific tag
you will apply the style with a function like
Public Function characterStyle(myElt, myxmlelement As InDesign.XMLElement,
valueOfChoice As String) As Long
myxmlelement.AssociatedObject.characterStyle =
mydocument.CharStyles(valueOfChoice)
End Function
with that I think You just have to make a function which read the xml
structure visible in the left side of the indesign application
I just developp in VB sorry about that
I hope that will help you
Olav if I'm wrong correct me ! if I'm right ..........
bye laurent
"amjb" <adam44@btopenworld.com> a οΏ½crit dans le message news:
1de69388.-1@WebX.la2eafNXanI...
> I am developing some XML doc from indesign, I need to map character styles
to XML Tags, with an apple script I.E:
>
> XML at the moment
>
> <para>The fox jumped over the</para>
>
> But want this
>
> <para>The fox <bodybold>jumped<bodybold> <italic>over<italic> the</para>
>
> Is there a way to do this with apple script, I have never used apple
script, so had a go with you script on the Adobe forum, but it's a bit above
my head.
>
> Can you help, can this even be done, even if you say no it can't at least
I can stop looking.
>
> Thanks
Technical Details
Message-ID:
<9B171CDA8A77F66BCB2945A122DA0108@in.WebX.la2eafNXanI>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-05!sn-xit-01!sn-xit-08!supernews.com!newsfeed.news2me.com!newsfeed.freenet.de!news.stealth.net!news.stealth.net!fr.clara.net!heighliner.fr.clara.net!newsfeed01.sul.t-online.de!t-online.de!WebXReferences:
<1de69388.-1@WebX.la2eafNXanI>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII X-Google-Thread: f939a,6f19215b8a69dbc1,start X-Google-Attributes: gidf939a,public X-Google-ArrivalTime: 2002-11-13 07:50:05 PST From: "laurent Battistelli" <l.battistelli@comidoc.fr> Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-05!sn-xit-01!sn-xit-08!supernews.com!newsfeed.news2me.com!newsfeed.freenet.de!news.stealth.net!news.stealth.net!fr.clara.net!heighliner.fr.clara.net!newsfeed01.sul.t-online.de!t-online.de!WebX Newsgroups: adobe.scripting.indesign Subject: Re: character styles to XML Tags? Message-ID: <9B171CDA8A77F66BCB2945A122DA0108@in.WebX.la2eafNXanI> Date: Wed, 13 Nov 2002 07:31:48 -0800 References: <1de69388.-1@WebX.la2eafNXanI> Lines: 51 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit