Quantcast
Channel: Adobe Community : Popular Discussions - InDesign SDK
Viewing all articles
Browse latest Browse all 78596

How to match nodes X elements by attribute value?

$
0
0

Hi all,

 

I have implemented my own ISAXDOMSerializerHandler for importing XML files. The thing I don't understand perfectly is how InDesign matches thenodes in the incoming xml file to the elements which exist in the document structure. I have experimented with the order of the elements/nodes and for me there are no rules which I could use.

 

Therefore I wonder if anyone has any experience with this topic. How to do the following:

 

1) you have a required attribute in your DTD named id for element <TXTELEM>

2) the template has a several text frames with the <TXTELEM> tag and every frame has its id attribute set to be unique

  - these frames were created in random order, or the attributes values were created/added/changed in random order

3) you have an XML file with several <TXTELEM> tags holding the ids

4) you want to import this XML into your document so that the id's match between the nodes and references

 

More questions:

I was thinking about creating custom IXMLImportMatchRecorder and its service - is it possible at all?

I was thinking also about searching for the reference with the right id everytime I receive StartElement in my SerializerHandler, but this feels really wrong.

 

I will appreciate any help,

 

Adam


Viewing all articles
Browse latest Browse all 78596


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>