Edit

Share via


XmlForm.Uri Property

Definition

Gets the Uniform Resource Identifier (URI) of a form.

public:
 abstract property System::String ^ Uri { System::String ^ get(); };
public abstract string Uri { get; }
member this.Uri : string
Public MustOverride ReadOnly Property Uri As String

Property Value

The Uniform Resource Identifier (URI) of the form.

Examples

In the following code example, the Uri property of the XmlForm class is used to display a form's URI in a message box.

MessageBox.Show(this.Uri); MessageBox.Show(Me.Uri)

Remarks

The value returned by the Uri property can be passed as the name of a form when it is accessed from the XmlFormCollection collection.

Depending on the state of the form, the Uri property will return a different value as described in the following table.

Previewing a form(Preview) formnameNew formformnamePreviously saved formThe full URL of the form, which can be a path name (C:\My Documents\MyForm.xml) or a valid URL if the form template was published to SharePoint, a Web server, or Microsoft SharePoint Server 2010 with InfoPath Forms Services.

This member can be accessed only by forms running in the same domain as the currently open form, or by forms that have been granted cross-domain permissions.

This type or member can be accessed from code running in forms opened in Microsoft InfoPath Filler or in a Web browser.

Applies to