Skip to main content
Rsfl
Inspiring
August 3, 2021
Question

Is there a way to preserve cross refs when migrating from structured to unstructured FM?

  • August 3, 2021
  • 2 replies
  • 300 views

Hi,
we have some documents where the existing structure is flawed (and no big help in the first place). Migrating to unstructured FM helps even out the problems, but by simply opening the documents in unstructured FM, all cross references are lost.

Is there a way, perhaps by means of a tool, to replace all cross refs with normal unstructured cross refs before migrating? The target elements have unique IDs, so these could be used to create markers for the links.

 

Robert

    This topic has been closed for replies.

    2 replies

    Rsfl
    RsflAuthor
    Inspiring
    August 5, 2021

    Thanks for your ideas! I might get back to Rick if a really slick solution is needed.

     

    BR,

    Robert

    frameexpert
    Community Expert
    Community Expert
    August 3, 2021

    This could be done with an ExtendScript script. I would approach it this way:

     

    1) For each element with an id, add a Cross-Ref marker to the paragraph with the id as its text.

    2) For each cross-reference, convert it from an Element cross-reference to a spot cross-reference, pointing to the new marker.

     

    If you are interested in a script like this, please contact me offlist. We can have a quick web meeting so I can see your documents and give you a price. Thank you. rick at frameexpert dot com

    Community Expert
    August 3, 2021

    Hi Rick,

     

    Just for my understanding, as I have only little experience with ExtendScript and almost no experience with structured FM. Wouldn't it be more futureproof to create regular cross-references?

    You might walk through all element cross-references and change them to paragraph cross-references. And insert regular cross-reference markers in the target paragraph.

    Or is this so much more difficult in ExtendScript?

     

    Best regards

     

    Winfried

    frameexpert
    Community Expert
    Community Expert
    August 3, 2021

    Internally, there is no real difference between a paragraph cross-reference and a spot cross-reference. The difference is in the syntax of the Cross-Ref marker. The syntax of a Cross-Ref marker for a paragraph cross-reference makes it show up based on the target Paragraph Format in the Cross-Reference dialog box. Since you already have unique ids, yours will just show up under Cross-Reference markers. But for existing cross-references, this should be fine.