When you design a form based on an existing XML document or XML Schema (XML Schema: A formal specification, written in XML, that defines the structure of an XML document, including element names and rich data types, which elements can appear in combination, and which attributes are available for each element.), and that XML document or XML Schema has been changed outside of Microsoft Office InfoPath 2003, you can update your form with the new XML document or XML Schema.
Note This procedure does not work for forms based on a database or Web service.
- In design mode, click Convert Main Data Source on the Tools menu.
- On the first page of the Data Source Wizard, click Browse.
- In the Open dialog box, browse to the updated XML document or XML Schema, and then click Open.
- On the next page in the Data Source Wizard, click Next.
- On the next page in the Data Source Wizard, do one of the following:
If a dialog box appears asking whether to use the values in the .xml file as the default data in your form, do one of the following:
- If you want to include an additional XML document or XML Schema in your form, click Yes, click Next, and then repeat steps 2 through 4.
- If you are finished adding XML documents or XML Schemas to your form, click No, and then click Finish.
Revise the form to match the new XML Schema. If an element has been removed in the updated XML Schema, for example, rebind or remove the controls that were previously bound to that element.
Test the form thoroughly.
- To use the values in the XML document to create default data for your form, click Yes. The values stored in the XML document will become the default values for the fields in your form.
- To use only the structure of the XML document and not its values, click No.
Note Testing the form includes previewing the form, as well as opening a new form and filling it out. Make sure to test any controls bound to new or modified fields.
- To republish the form, click Publish on the File menu.
Note The information in this topic may not apply if you are working with a form designed using Microsoft Office InfoPath 2003 without the service pack installed.