• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Problem Threading Existing Text Frames to Each Other

New Here ,
Dec 22, 2024 Dec 22, 2024

Copy link to clipboard

Copied

I have inherited some documents from a client where all the text frames are not threaded. When I click the out-port of a frame and then hover over the area of the in-port frame that I want to thread it to, I see the cursor change to the thread icon, but when I click, it creates a blank text frame and threads to it. 
All frames are on the same layer and unlocked. I am showing all frames but I am unable to target the in-port of the frame I want to link to. Is there a way to display the in/out ports without hovering over them? Is there something I am missing in doing what should be a simple task?
Thanks in advance for any help.

TOPICS
Performance

Views

54

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 23, 2024 Dec 23, 2024

Copy link to clipboard

Copied

Hard to know what's going on without seeing the file or some screenshots etc. 

 

Here's a script if it helps to thread them for you - but best to find out what's causing it not to work.

 

Be interested to see more of the file itself or your screenshots/layers panel etc. 

 

// Check if at least two text frames are selected
if (app.selection.length < 2) {
    alert("Please select at least two text frames.");
} else {
    try {
        // Store selected text frames
        var selectedFrames = app.selection;
        
        // Sort selected items based on geometricBounds (if needed for order)
        selectedFrames.sort(function (a, b) {
            return a.geometricBounds[1] - b.geometricBounds[1]; // Sort by x-coordinate
        });

        // Loop through and thread the text frames
        for (var i = 0; i < selectedFrames.length - 1; i++) {
            if (selectedFrames[i].constructor.name === "TextFrame" && selectedFrames[i + 1].constructor.name === "TextFrame") {
                selectedFrames[i].nextTextFrame = selectedFrames[i + 1];
            } else {
                alert("Selected items must be text frames.");
                break;
            }
        }

        alert("Text frames have been threaded successfully!");
    } catch (e) {
        alert("An error occurred: " + e.message);
    }
}

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 23, 2024 Dec 23, 2024

Copy link to clipboard

Copied

LATEST

@Synthtony

 

You don't have to click exactly over the in-port - just over the destination TextFrame.

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines