Page 1 of 1
Wrap text
Posted: Wed Mar 30, 2011 8:46 am
by RICHARD RUTA
To maintain an existing file structure in an application, I'd like to create an entry screen field that automatically wraps at 80 characters: much the way this screen works. Then for presentation, I'd like the same text automatically to wrap at 40 characters. Is this possible?
Re: Wrap text
Posted: Wed Mar 30, 2011 11:49 am
by Rob
Use a Text Area widget to enter a long field. The width of the widget along with the font size and average word length will determine where the text wraps. Bind the value property of the text area to a long field (for example 1000A) and split this into multiple 80A lengths with RPG logic. Concatenate the 80A fields to build the 1000A field to redisplay.
Of course the point where the text wraps on screen will bear no relationship to where the RPG code will split or concatentate the field into multiple 80A fields.