lastdelimiter
Hi,
I have a memo that can contain text that uses more than one line on the report. If the user do not put in a CR only the first line is shown on the report. To avoid this I want to put in a CR at the after a word at a given length using the function lastdelimiter looking for the last space in my substring. But as far as I can tell this function is not implemented in Fast Report.
1. Is there another way for me to do this without using this function?
2. Will lastdelimiter be implemented in a future release of Fast Report?
I am currently using Fast Report 4.9.32
I have a memo that can contain text that uses more than one line on the report. If the user do not put in a CR only the first line is shown on the report. To avoid this I want to put in a CR at the after a word at a given length using the function lastdelimiter looking for the last space in my substring. But as far as I can tell this function is not implemented in Fast Report.
1. Is there another way for me to do this without using this function?
2. Will lastdelimiter be implemented in a future release of Fast Report?
I am currently using Fast Report 4.9.32
Comments
If yes, all you need is to create a user function. For example, I have a function that removes the ending CrLf of the memo.text, called by me as 'DoTrim':
In Delphi:
then you implement it (still in your .pas file):
And add this too:
Then you can use it in the script, for your memo:
All you need to do is follow those steps to create a function that does exactly what you neeed (not what I showed here).
Search for 'OnUserFunction' in the pdf help files and you will find more about it.
frxReport1.OnUserFunction := CustomReportFunction;
frxReport1.AddFunction(...);
as the last thing just before you call the show/preview methods.
Otherwise, the only thing I can suggest is to read the manual, I learned from there.