GrooveForms2.ReadInfoPathTemplate Operation

The ReadInfoPathTemplate operation returns the template that defines the specified InfoPath form. The template defines the fields and visual design of the form but does not contain any data. When you are designing or publishing a form, InfoPath stores the template in an .xsn file.

HTTP Post URL

The HTTP Post URL targets the Forms tool. This URI is provided by the GrooveTools.Read operation in the ToolData element.

Input Message Header

GrooveRequestHeader specifies information common to all Groove Web Services, including the Groove Identity URL and the Groove Request key.

Input Message Parameters

<FormURI />
Element Data type Description

FormURI

xs:anyURI

Specifies the InfoPath form. FormURI values are returned by the ReadForms operation in the URI element.

Output Message Header

GrooveResponseHeader specifies the Response key.

Return Value

<ReadInfoPathTemplateResult />
Element Data type Description

ReadInfoPathTemplateResult

InfoPathTemplate

Contains the InfoPath template and the metadata describing the template.

Remarks

If the FormURI specifies an HTML form rather than an InfoPath form, this operation returns an exception.

Example

The proxy code generated by Microsoft Visual Studio® 2005 provides access to the InfoPathTemplate.Contents element, which contains the InfoPath template, as a byte array named Item. The example below illustrates how to use the return values from the ReadInfoPathTemplate operation.

GrooveForms2.InfoPathTemplate ipTemplate = forms2Svc.ReadInfoPathTemplate(formURI);

byte [] templateContents = ipTemplate.Contents.Item;
string templateURN = ipTemplate.URN;
string publishURL = ipTemplate.PublishURL;
string version = ipTemplate.Version;

See Also

Reference

GrooveForms2 Web Service
InfoPathTemplate Complex Type

Concepts

Accessing Forms Tool Design Information
Getting Information About the InfoPath Template