Specific Selection to Merge Text
Hello all, beginner-ish javascripter here. I've been looking into creating a script for my job to automate the merging of text elements on my floorplans, and have thus far been successful. The main() function in my script takes a single text group and merges the elements inside the group together, to form one block of text, then groups it again.
The issue I am having is with the next step, which is running a loop to perform the main function on each appropriate text item in the plan at once. I believe the issue I'm running into doesn't have to do with the main function, as it works just fine if the user goes in and selects each text piece they want to merge. But that's just a theory, and after banging my head against this for the past 6 hours, I'm running out of ideas.
I'll omit the main() function for now, as it's pretty long. This is my latest attempt:
