When you design a Microsoft Office InfoPath form template, you must consider how to lay out, or arrange, the elements on the form template.
Generally, you should organise the different parts of your form template so that people who fill it out can move through the form in a logical manner. In addition, it is a good idea to align text boxes, check boxes, and other elements along the horizontal and vertical lines of an imaginary grid. You can use layout tables (layout table: A collection of cells used to arrange form content such as text or controls.) to define the boundaries of your grid and help line up elements on the form template.
Ideally, you should design a form template that is visually appealing and easy for others to use. Layout tables can help you achieve both of these goals.
The Layout task pane offers a collection of predesigned
layout tables that you can use in your form template to give it a visual
A layout table is like any other table, except that it is used only for layout purposes and not for data presentation. In addition, unlike other tables, layout tables do not have visible borders by default. When you design your form template in design mode, the layout table's borders are represented by dashed lines, so that you know you are working within the table. However, when users fill out a form that is based on your form template, those borders don't appear.
Among other things, you can use layout tables to organise controls, to separate one section from another, to create header and footer sections, and to hold logos and other graphics.
In the following example, a layout table is used to organise text boxes inside a section (section: A control on a form that contains other controls.) on a form template.
1 This layout table has two rows.
2 There are three columns in the second row. The center column is used only for spacing purposes.
If you want to add or remove rows and columns from a layout table, click any of the options in the Merge and split cells list in the task pane. If the layout tables in the Layout task pane don't meet your needs, you can insert a custom layout table with the exact number of rows and columns that you want.
You can also use the Layout task pane to quickly insert scrolling regions (scrolling region: A control that contains other controls and that can display vertical or horizontal scroll bars. Scrolling regions are used for layout purposes only and are not bound to fields or groups in the data source.) and horizontal regions in your form template, which are described in detail in the following section.
In addition to layout tables, you can use layout-related controls, such as sections or repeating sections (repeating section: A control on a form that contains other controls and that repeats as needed. Users can insert multiple sections when filling out the form.), to help you design your form template. When you insert a layout-related control onto your form template, you are essentially inserting an empty container for storing other controls.
The following table provides brief descriptions of the controls that are most commonly used for layout purposes.
|Section||A control that contains other controls. For example, in an insurance claim form template, you might use a section to group a set of text boxes that are used to collect contact information from policyholders.|
|Optional section||A control that contains other controls but does not appear on the form unless the user chooses to add it. For example, although all employees in a company might use a goal-setting section in their performance review forms, only managers might choose to add an optional section about leadership goals.|
|Repeating control||A control, such as a repeating section or repeating table (repeating table: A control on a form that contains other controls in a table format and that repeats as needed. Users can insert multiple rows when filling out the form.), that lets users expand the contents of a form when it is filled out and display only the necessary number of entries in a series. For example, you can use a repeating table to collect itemised expenses in an expense report form template.|
|Scrolling region||A control that contains other controls, retains a fixed size, and includes scroll bars so that users can scroll to see information that is out of view. Scrolling regions can be useful when a section of a form template contains a lot of data, and users do not need to see all of the data at one time. For example, if you use a repeating table to display numerous records from a database, you can insert the repeating table inside a scrolling region to display just a few of the records at a time. Because scrolling regions are used exclusively for layout purposes, they are not bound to fields or groups in the data source. Scrolling regions are not supported in browser-compatible form templates (browser-compatible form template: A form template that is designed in InfoPath by using a specific compatibility mode. A browser-compatible form template can be browser-enabled when it is published to a server running InfoPath Forms Services.).|
|Horizontal region||A control that contains other controls and can be placed in a horizontal formation on a form template. For example, when several horizontal regions are placed side-by-side, the regions will wrap, or flow, to the next line as the size of the screen changes. Because horizontal regions are used exclusively for layout purposes, they are not bound to fields or groups in the data source. Horizontal region controls are not supported in browser-compatible form templates.|
|Choice group||A control that presents a set of mutually exclusive choices to users. A choice group contains choice sections (choice section: A control that contains other controls and is used to represent a single choice within a set of mutually exclusive choices. Users can replace one choice section with another when filling out a form.), one of which appears as the default choice in a form. Those choice sections contain other controls. For example, address information in an employee information form template can be formatted as a choice group that contains choice sections. Each choice section contains controls with the correct address syntax for a specific country or region. When employees fill out a form that is based on the form template, they can replace the default address section with one that applies to their country or region.|
Use the following tips to help you refine the appearance, size, and other aspects of layout tables and layout-related controls.