I did something like this for a project a few months ago. In my case I was
breaking a large amount of text into separate pages for printing.  What I
did was a recursive function that tried to fit a block of text into a text
field, then if the text was too long the function split the text block in
half and called itself with each half.

I think the recursive method is probably faster for large amounts of text,
but for smaller fields your method would probably yield better results.

--
~Trout
http://www.amongtrout.com

On 3/29/06, Chris Hill <[EMAIL PROTECTED]> wrote:
>
> I've searched a lot on google and the list and haven't found much, so
> maybe I'm missing something obvious again.
>
> Basically I need to fill a text field, and when that text field is full,
> i should start filling the next one. My current idea is:
>
> Break the text into space delimited tokens.
> Keep adding tokens and checking maxscroll to see if it is equal to 1.
> If maxscroll equals 1 then subtract the last token.
> Move on to the next text field.
>
> Not an ideal solution, but the only one that I think will work. Has
> anyone done anything similar?
>
> Thanks
> Chris
> _______________________________________________
> [email protected]
> To change your subscription options or search the archive:
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
> Brought to you by Fig Leaf Software
> Premier Authorized Adobe Consulting and Training
> http://www.figleaf.com
> http://training.figleaf.com
>
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to