iNTERFACEWARE Products Manual > Installing and Using Chameleon > Using Python Scripting > Python Scripting Examples > Message Manipulation > Split long report into fields of limited length |
|
Looking for Iguana v.5 or v.6? Learn More or see the Help Center.
Quite often we have long report text in a single field and have to split it to several lines shorter than the maximum field length. In this example we can have a maximum to 80 characters in each NTE-3 field. We will split the at the last complete word not exceeding 80 characters. Then we add another NTE segment, and place the extra text in the NTE-3 field of the new segment.
Here are links to the script, vmd and test data files: Here is the sample Scripted Transformation script:
Here is the test data, with '~' encoded as '\R\':
Please send an email to support@interfaceware.com if you need more help. |