× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Um.... ya... I just would not feel right doing that. I did a loop and it
works great.

-----Original Message-----
From: Joep Beckeringh [mailto:joep@beckeringh.myweb.nl]
Sent: Friday, May 24, 2002 4:22 PM
To: rpg400-l@midrange.com
Subject: RE: Text wrapping question


How about (hang on!):
%subst(string:1:(%len(%trimr(%subst(string:1:37)))))

That should give the next programmer something to think about!

Joep Beckeringh


> -----Oorspronkelijk bericht-----
> Van: rpg400-l-admin@midrange.com
> [mailto:rpg400-l-admin@midrange.com] Namens Wills, Mike N. (TC)
> Verzonden: donderdag 23 mei 2002 18:47
> Aan: 'rpg400-l@midrange.com'
> Onderwerp: RE: Text wrapping question
>
>
> But that won't work in this case, will it?
>
> >>>Let's say this is my string:
> This is a sentence that is longer than what will fit in my field.
>
> >>>Currently my report looks like this (%subst(string:1:37)):
> This is a sentence that is longer tha
> n what will fit in my field.
>
> >>>I want it to look like this (%subst(string:1:last space
> but less than
> 37)):
> This is a sentence that is longer
> than what will fit in my field.

_______________________________________________
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@midrange.com
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/cgi-bin/listinfo/rpg400-l
or email: RPG400-L-request@midrange.com
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.


As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.