InfoPath 2007 Frequently Asked Questions (FAQ)
Frequently Asked Questions (FAQ) about InfoPath 2007 and Forms Server 2007.
Questions
- Which InfoPath 2007 features are not supported in InfoPath 2003?
- What are browser-compatible forms?
- Can I use browser-compatible forms without installing Microsoft Office SharePoint Server 2007 (MOSS)?
- What is Forms Server?
- What do I need to be able to run Forms Server?
- How do I make InfoPath 2007 forms to be compatible with InfoPath 2003?
- How do I retrieve the value of an InfoPath field through code?
- How do I set the value of an InfoPath field through code?
- How do I call a web service through code?
Answers
Which InfoPath 2007 features are not supported in InfoPath 2003?
A brief overview can be found here: InfoPath 2007 features that are unavailable in InfoPath 2003.
-
What are browser-compatible forms?
InfoPath 2007 introduced the possibility to fill out InfoPath forms by using a browser such as Internet Explorer, Firefox, Netscape, or Safari. These types of forms are called InfoPath 2007 browser-compatible forms. For a complete list of browsers that can be used to fill out InfoPath forms, see Plan browser support (Office SharePoint Server).
For more information see Introduction to browser-compatible form templates.
-
Can I use browser-compatible forms without installing Microsoft Office SharePoint Server 2007 (MOSS)?
Yes, you can, but you will have to install Forms Server to be able to run browser-compatible forms.
What is Forms Server?
Forms Server is the extracted version of Forms Services that comes with Microsoft Office SharePoint Server 2007 (MOSS). It is sold and can be used separately from MOSS to run and fill out InfoPath 2007 browser-compatible forms.
For more information see Introduction to Office Forms Server.
What do I need to be able to run Forms Server?
Windows SharePoint Services 3.0, which you can download, install, and use free of charge.
How do I make InfoPath 2007 forms compatible with InfoPath 2003?
- Open the form template that you want to save in InfoPath 2003 format.
- On the File menu, click Save As.
- In the Save as type list, click InfoPath 2003 Form Template.
- Click Save.
-
How do I retrieve the value of an InfoPath field through code?
In C# code:
XPathNavigator nav = MainDataSource.CreateNavigator();
string fieldValue = nav.SelectSingleNode("//my:field1", NamespaceManager).Value;In VB.NET code:
Dim nav As XPathNavigator = MainDataSource.CreateNavigator()
Dim fieldValue As String = nav.SelectSingleNode("//my:field1", NamespaceManager).Value
-
How do I set the value of an InfoPath field through code?
In C# code:
XPathNavigator nav = MainDataSource.CreateNavigator();
nav.SelectSingleNode("//my:field1", NamespaceManager).SetValue("myValue");In VB.NET code:
Dim nav As XPathNavigator = MainDataSource.CreateNavigator()
nav.SelectSingleNode("//my:field1", NamespaceManager).SetValue("myValue") How do I call a web service through code?
In C# code:
// Create an XPathNavigator object to navigate the data source of the web service
XPathNavigator nav = DataSources["HelloWorld"].CreateNavigator();
// Set the value of the parameter to pass to the web service
nav.SelectSingleNode("//dfs:queryFields/tns:HelloWorld/tns:name", NamespaceManager).SetValue("myValue");
// Call the web service
DataSources["HelloWorld"].QueryConnection.Execute();
// Retrieve the results returned by the web service
string results = nav.SelectSingleNode("//dfs:dataFields/tns:HelloWorldResponse/tns:HelloWorldResult", NamespaceManager).Value;where HelloWorld is the name of a data connection to a web service.
In VB.NET code:' Create an XPathNavigator object to navigate the data source of the web service
Dim nav As XPathNavigator = DataSources("HelloWorld").CreateNavigator()
' Set the value of the parameter to pass to the web service
nav.SelectSingleNode("//dfs:queryFields/tns:HelloWorld/tns:name", NamespaceManager).SetValue("myValue")
' Call the web service
DataSources("HelloWorld").QueryConnection.Execute()
' Retrieve the results returned by the web service
Dim results As String = nav.SelectSingleNode("//dfs:dataFields/tns:HelloWorldResponse/tns:HelloWorldResult", NamespaceManager).Valuewhere HelloWorld is the name of a data connection to a web service.
Related InfoPath Articles:
- Force InfoPath browser-enabled form to open in the browser
- How to get HTML tags to appear as HTML and not as plain text in a Rich Text Box
- How to get the current row number of a repeating table in InfoPath using VB.NET code
- Programmatically select all items in a multiple-selection (multi-select) list box
- "This form template is browser-compatible, but it cannot be browser-enabled on the selected site" message
Copyright: This article may not be used on web sites (whether personal or otherwise), copied, disseminated, altered, printed, published, broadcasted, or reproduced in any way without an expressed written consent. The techniques demonstrated in this article may be used within any Microsoft InfoPath project. This article is provided without any warranties. Copyright for this article is non-transferrable and remains with the author.