Skip to main content

Create DOCX Output - Knowledgebase / Lasernet / Lasernet Training / Lasernet Form Editor 9 - Rich Text and Spreadsheet - Formpipe Support Portal

Create DOCX Output

Authors list


The DOCX format is an output format used for creating an output. The Forms Engine retrieves data from the input file, processes it and adds defined fields to the output along with static elements and text added by a user while modifying the output in the Editor.

As an input, the DataSet format is always used.

Dealing with an output of the DOCX format, you can use a Microsoft Word type interface.

In this exercise, you are proposed to create an output in the DOCX format.

Exercise

Download and import the attached configuration called 02. Create DOCX Output in Lasernet Developer 9. Afterwards, go to the Forms section and open the Sample form.

To create an output of the DOCX format, follow the steps listed below:

1. Open a grab file named Sample. To this end, first, on the Form menu, click Select Grab File(s).

2. In the Select Grab File(s) dialog that opens, select the Sample file, and then click Open.

3. Open a template based on which you want to create the output. To this end, click Open Template, select the one from the list, and then click Open.

4. Start creating your output document. First, click the View Gridlines button to show lines of all grids available in the output. It could make formatting the document easier.

5. Add fields from the input to the output by dragging them. Add the following fields in the order specified below:

  • contactname
  • shipname
  • shipaddress
  • shipcity
  • shipcountry

Once done, make sure that the following font styles are specified for the added lines:

  • the contactname line: Segoe UI, 14 pt, Bold;
  • the rest lines: Segoe UI, 12 pt.

6. Add data for such fields as ORDER #, FREIGHT, ORDER DATE, REQUIRED DATE and SHIPPED DATE. Once done, make sure that the following font styles are specified for the added lines:

  • the ORDER  line: Segoe UI, 12 pt, Bold;
  • the rest lines: Segoe UI, 12 pt.

7. You can then drag fields belonging to the nested table. To this end, select the required fields on the nested table by holding down the CTRL key while clicking your mouse button on each field you want to add in the required order. The following order is proposed:

  • quantity
  • productname
  • unitprice
  • discount
  • netprice

Those fields are then added to the output in the order you have selected them.

You are now proposed to format the table using the required tools on the toolbar as well as commands of the context menu which appears by right-clicking the table, so the table looks like it is shown on the picture below:

Right click > Table Properties > Borders and Shading to set the colors and styles for Border and Shading.

Right click > Font to set the colors and styles for Font and Styles.

As it was stated above, some data of the output is based on the fields of the input. Making all code fields visible in your output allows you to learn which data in the output is based on the input data. It can make creating and editing a report easier. To activate this mode, press ALT+F9. Your output can look then as follows:

If you want to show field code for a definite item, right-click the item, and then click Toggle Field Codes on the context menu that appears. The rest code fields available in the output are not then shown, but the selected one.



Helpful Unhelpful

Add a comment

Please log in or register to submit a comment.

Need a password reminder?

Share