Report Wizard introduces three directives: #forrow, #forcol, and #forpage. These directives allow you to use Velocity to generate outputs other than web documents. With these directives, you can eliminate problems that usually occur when using Velocity to generate an rtf document, for example, #foreach generates broken rows in a table.

#forrow
This directive is used in the Rich Text Format, OpenDocument text, and OpenDocument spreadsheet, Microsoft Word Document (DOCX), and Microsoft Excel spreadsheet (XLSX) documents. Whenever #forrow iterates through a list, it creates a row in a table.

#forcol
This directive is used only in Microsoft Word document (DOCX), Microsoft PowerPoint presentation (PPTX), OpenDocument spreadsheet, and Microsoft Excel spreadsheet (XLSX). Whenever #forcol iterates through a list, it creates a column in a table.

#forpage
This directive is used in Rich Text Format document, OpenDocument Text, OpenDocument spreadsheet, OpenDocument presentation, Microsoft Word document (DOCX), Microsoft Excel spreadsheet (XLSX), and Microsoft PowerPoint presentation (PPTX). Whenever #forpage iterates through a list, it creates a new page in Rich Text Format, OpenDocument text or Microsoft Word (DOCX). It also creates a new sheet in OpenDocument spreadsheet or Microsoft Excel spreadsheet (XLSX), or a new slide in OpenDocument presentation or Microsoft PowerPoint presentation (PPTX).