Scenario/Problem: | You want to set up the form for tracking changes. |
Solution: | Create the controls and fields needed for tracking changes as explained here. |
The initial setup starts with defining the field and text box for the form entry you want to track changes.
To define the field and text box, follow these steps:
1. | Design a new form in InfoPath Designer and use a single-column table layout.
|
2. | Place
a text box in the second row and provide a name for the field. (For
this example, I am using Description.) This is the field for which you
want to track changes.
|
3. | Make the text box multiline and stretch it out within the table row.
|
4. | Split the cells of the first row and enter a field label in the first column.
|
5. | Make
the second column smaller by dragging the line that separates the two
columns. The second column will be used for controls as explained
within subsequent sections.
|
Your form should now look similar to Figure 1.
The next steps for the initial setup are to provide the storage for the changes being made to the field:
1. | Drag a repeating section under the text box you added in the previous steps.
|
2. | Modify the properties of the repeating section and uncheck the Allow Users to Insert or Delete the Sections option.
|
3. | In the Fields pane, rename the first group to groupTrackChanges.
|
4. | Rename the repeating group2 to groupChanges.
|
5. | Under the groupChanges, add a field named NumberOfChanges and make its data type a Whole Number (Integer).
|
6. | Under the groupChanges, add a field named Changes and make its data type Rich Text (XHTML).
|
7. | Under the groupChanges, add a field named UserName and leave its data type as Text (String).
|
8. | Drag the Changes field into the repeating section on the form.
|
9. | Resize the rich text box such that it is the same as the normal text box and make it read-only.
|
Your form should now look similar to Figure 2.