frequently asked questions

All your questions in one place.

Add a text file in a large text

You can need to use a large text in a report, and this text is subject to change.

 

As an example you have a text for Christmas holidays, one for Halloween, etc... You don't want the users to have to modify the report, but rather en external text file. This can be achieved in a way that allows the report smoothly even if the external file is missing.

Example

*/ If the file specified in file-path exists, then its content is displayed, otherwise the text box is left empty.

iif(file(file_path), StringReplace(filetostr(file_path)), '')

*/ If C:\my_text.txt exists, then its content is used, otherwise the text-box is left empty.

iif(file('C:\my_text.txt'), StringReplace(filetostr('C:\my_text.txt')), '')

Did you find this article useful?

0 out of 0 found this helpful