Quantcast
Channel: Adobe Community : Popular Discussions - InDesign Scripting
Viewing all articles
Browse latest Browse all 15932

[AS] Help: Change text in overflowing?

$
0
0

Hello again,

 

i'm trying to fill text frames in my document with a randomtext from an array. Works fine by now.

But not knowing how many characters fit in the text box, which has space for a single line about 10 words, i'll try to repeat the random process until theres no overflow in the box.

 

 

The problem is this: When I change a text of the text frame, and it overflows, ill change the text again – but only the visible text gets overwritten, leaving the overflowing rest in the box and keeps adding up and never finishes the repeat-loop.

 

ifclassofmyPageItemasstring = "text frame" then

                     

                      settextofmyPageItemto "" & myTextFill()

                           

                                                    repeatuntiloverflowsofmyPageItem = false

                                                                      settextofmyPageItemto "" & myTextFill()

                                                            endrepeat

                                                  endif


Its the thingy with text of text frame…how do I overwrite every visible and non visible text in the box, any suggestions?


Viewing all articles
Browse latest Browse all 15932

Trending Articles



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