Perl "one-liners" have a great many uses for quick data processing tasks, often replacing the UNIX tools grep, sed, and awk. For example, a simple "grep" function can be written as:

perl -lne '/pattern/ and print' file.txt

which improves on the standard grep function by allowing the extended features of Perl regular expressions to be used.

However, this form of processing is only suitable for data that can be read (or needs to be written) in plain text format. XLSperl lets you use the same commands to process and create Microsoft Excel files, e.g. the following command will "grep" an Excel document:

Note that once a filehandle has been used with the XLSprint function, to avoid corruption of the generated Excel file the 'normal' print function should not be used on that filehandle, i.e. do not do this: