Lab 1: Publishing an InfoPath 2007 Form Template to a Server Running InfoPath Forms Services

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Learn how to create a browser-enabled InfoPath 2007 form template, review the different server-specific options, and publish the form template to an Office SharePoint Server 2007 document library. (5 printed pages)

February 2007

**Applies to:**Microsoft Office InfoPath 2007

Contents

  • Lab Objectives

  • Lab Setup and Requirements

  • Scenario

  • Exercises

  • Conclusion

  • Additional Resources

Download: InfoPath 2007 Sample: Training Labs.

Lab Objectives

After completing this lab, you will be familiar with the following:

  • The Design Checker task pane

  • Server-specific form options

  • Publishing a form template to a server running InfoPath Forms Services

Lab Setup and Requirements

To complete this lab, you must have the following:

  • Microsoft Office InfoPath 2007

  • Access to an Microsoft Office SharePoint Server 2007 or Microsoft Office Forms Server 2007 server as a Farm Administrator

  • Access to a site collection

Scenario

The IT department at Contoso has designed a status report form template using Office InfoPath 2007. They are now ready to publish the form template to a server so that users who do not have Office InfoPath 2007 installed on their computer can access the form using a Web browser. Before proceeding, the form designer must prepare the form template for the server, modify the server-specific options, and then publish the form template to the server.

Exercises

Publishing a Form Template to a SharePoint Server Library

One way to share a form template with other people in your organization is to publish it to a SharePoint Server library. This allows team members to fill out, save, and view the status report, regardless of whether they have Office InfoPath 2007 installed on their computers. In the following exercise, you will publish the status report form template to a document library created specifically for this use.

To open the form template

  1. Start InfoPath.

  2. In the Getting Started dialog box, click Design a Form Template.

  3. In the Design a Form Template dialog box, click On My Computer.

  4. Select the Status Report (Simple) form template contained in the download associated with this lab, and located in the C:\2007 Office System Developer Resources\Code Samples\InfoPath2007SampleTrainingLabs folder, and then click Open.

    The Contoso status report form opens in design mode.

  5. Save the Status Report (Simple) form template on the desktop, and use this copy to publish to a SharePoint Server library.

To ensure that the form template is compatible with the server

  1. Click the drop-down arrow at the top of the Design Tasks task pane, and then click Design Checker, as shown in Figure 1.

    Figure 1. Opening the Design Checker task pane

    Open the Design Checker task pane

  2. On the Design Checker task pane, click Change Compatibility Settings.

  3. In the Form Options dialog box, check Design a form template that can be opened in a browser or InfoPath, and then click OK.

  4. Review any errors or warnings that appear in the Design Checker task pane list, as shown in Figure 2.

  5. To learn more about an individual error, select it in the list.

    Note

    There are no errors in the status report form template that prevent the form from working in the browser.

Figure 2. Viewing compatibility errors

Design Checker task pane with Errors

When all errors have been addressed, the form template is ready to be published to the server. However, you may want to specify any server-specific options before you publish the form template. For example, you can modify the toolbars that appear above and below the form in the browser. By default, both toolbars are available on the form when it is being filled out in the browser, but you can choose to show the top toolbar only, the bottom toolbar only, or no toolbars at all.

To change server-specific options

  1. On the Tools menu, click Form Options.

  2. In the Form Options dialog box, click Browser in the Category list.

  3. To disable the toolbar on the top of the form, clear the Show toolbar at top of form check box.

  4. To disable the toolbar on the bottom of the form, clear the Show toolbar at bottom of form check box.

    Note

    If you remove both toolbars, you will not be able to save the form template to the document library.

  5. To change the language of the interface elements, such as toolbars and dialog boxes, select the language you want from the Form language list.

    By default, the form language is based on the language that the form was designed in. The language selected should be one of the server-supported languages and should be installed on the server.

Table 1 describes the buttons that are available on the toolbar. By default, all the buttons are available.

Table 1. Toolbar buttons

Button

Description

Submit

Begins the submission process if submit has been enabled for the form template.

Save

Saves the form to the document library or to the specified save location.

Save As

Saves the current form to the document library or to the specified save location with a different form name.

Close

Closes the current form.

Views

Used to switch between views if more than one view of the form template is available.

NoteNote
If you do not want users to switch between views directly from the toolbar, disable this button.

Print View

Switches to a view with a layout for browser printing.

Update

Updates the form data with the server. This button will trigger any server-related actions associated with this form.

To disable one of the buttons, clear the check box next to the button you want to disable, as shown in Figure 3.

Note

You can change the captions of the buttons by editing the solution manifest (.xsf) file.

Figure 3. Setting server-specific form options

Browser-enabled Form Options

After you specify the appropriate server-specific options, you are ready to publish the form template to the document library.

To publish a form template to a library

  1. On the File menu, click Publish.

  2. On the second page of the Publishing Wizard, click To a SharePoint server with or without InfoPath Forms Services, and then click Next.

  3. In the Enter the location of your SharePoint or InfoPath Forms Services site box, type the name of your site, and then click Next.

  4. On the next page of the wizard, ensure that Enable this form to be filled out by using a browser is checked at the top of the page.

  5. Click Document Library, and then click Next.

  6. Click Create a new document library, and then click Next.

  7. In the Name box, type Status Report Simple, and then click Next.

  8. Click Add to add a SharePoint column.

  9. In the Select a Field or Group dialog box, select the Date field.

  10. In the Column name box, replace Date with Status Report Date, and then click OK.

    This text will appear at the top of the column in the SharePoint Server library.

  11. Repeat steps 8, 9, and 10 to add more columns to the document library. When finished, click Next.

  12. To complete the wizard, click Publish.

The final page of the wizard indicates that the form was successfully published. This page contains a link to preview the form in the default browser.

To open the published form

  1. Browse to the SharePoint Server library.

  2. On the document library toolbar, click New.

    If Office InfoPath 2007 is installed, the form is opened in InfoPath. If Office InfoPath 2007 is not installed, the form is opened in the browser.

To make the form open only in the browser

  1. Browse to the SharePoint Server library.

  2. On the document library toolbar, click Settings, and then click Form Library Settings.

  3. In the General Settings section, click the Advanced Settings link.

  4. In the Browser-enabled Documents section of the Form Library Advanced Settings page, as shown in the following, select the Display as Web page option.

    Figure 4. Change the option to always open in the browser

    Display the Form in the Browser

  5. Click OK, and browse back to the SharePoint Server library.

Now the form will always be opened in the browser, regardless of whether Office InfoPath 2007 is installed.

Conclusion

Now that you have completed this lab, you can prepare a form template for publishing to a server, set server-specific options that will appear on the form when it is opened in a Web browser, and publish the form template in a SharePoint Server library.

To learn how to deploy a form template to a server running InfoPath Forms Services, see Lab 2: Deploying and Managing InfoPath 2007 Forms.

Additional Resources

For more information about developing with InfoPath, see the following resources: