6. Add Your Template Part as a Custom Control
Scenario/Problem: | You want to make the form template part available for use. |
|
Solution: | Add your form template part as a custom control. |
After you have saved your template part, you may add
it as one of the InfoPath controls such that each time you design a new
form, your template part is available for use.
To add your template part to InfoPath, follow these steps:
1. | From InfoPath Designer, expand the Controls menu from the Home top ribbon bar.
|
2. | Select Add or Remove Custom Controls, as shown in Figure 3, to open the Add or Remove Custom Controls dialog. The dialog appears as shown in Figure 4
and allows you to manage your template parts.
|
3. | Click the Add button. The Add Custom Control Wizard appears, as shown in Figure 5, and steps you through the template part addition.
|
4. | Leave the Template Part option selected and click Next.
|
5. | Browse to the xtp2 file you created when saving your template part and click Finish, as shown in Figure 6, to add that part as a custom control.
|
6. | Click Close on the confirmation window.
|
7. | Click OK on the Add or Remove Custom Controls dialog.
|
Your form template part is now available in the Controls list, as shown in Figure 7, and may be used in SharePoint forms.