Edytuj

Udostępnij za pośrednictwem


SolutionObject Interface

Definition

Corresponds to a Microsoft Office InfoPath form template.

public interface class SolutionObject : Microsoft::Office::Interop::InfoPath::Solution
[System.Runtime.InteropServices.Guid("096CD557-0786-11D1-95FA-0080C78EE3BB")]
public interface SolutionObject : Microsoft.Office.Interop.InfoPath.Solution
type SolutionObject = interface
    interface Solution
Public Interface SolutionObject
Implements Solution
Derived
Attributes
Implements

Examples

In the following example, a reference is set to the Solution object, then the code gets the name of the person who authored the form from the .xsf using the DOM property of the Solution object. A test is then made to determine if there is an author value, and the results are displayed in a message box.

public void SolutionInfo_OnClick(DocActionEvent e)
{
<span class="label">Solution</span> solution = thisXDocument.<span class="label">Solution</span>;
 string solutionVersion = solution.Version;
 string authorText;
 IXMLDOMNode author = solution.DOM.selectSingleNode("xsf:xDocumentClass/@author");

 if (author != null)
 {
  authorText = author.text;
 }
 else
 {
  authorText = "Author not available.";
 }

 thisXDocument.UI.Alert("Version: " + solutionVersion + "\nAuthor: " + authorText);
}

Remarks

This type is a wrapper for a coclass that is required by managed code for COM interoperability. Use this type to access the members of the COM interface implemented by this coclass. For information about the COM interface, including a link to descriptions of its members, seeSolution2.

The SolutionObject object implements properties for getting information about a form template, including its version number, the Uniform Resource Locator (URL) of its extracted form files, the URL it was loaded from, and an XML Document Object Model (DOM) containing its form definition (.xsf) file.

The SolutionObject object is accessed through the Solution property of the XDocument object.

Properties

DOM

This member is a wrapper for a member of a COM interface that has been superseded by a later version. The later version of this interface implements all members of earlier interfaces and additional new members. For information about this member as it is implemented in the later interface, including usage, remarks, and examples, seeDOM.

(Inherited from Solution)
PackageURL

This member is a wrapper for a member of a COM interface that has been superseded by a later version. The later version of this interface implements all members of earlier interfaces and additional new members. For information about this member as it is implemented in the later interface, including usage, remarks, and examples, seePackageURL.

(Inherited from Solution)
URI

This member is a wrapper for a member of a COM interface that has been superseded by a later version. The later version of this interface implements all members of earlier interfaces and additional new members. For information about this member as it is implemented in the later interface, including usage, remarks, and examples, seeURI.

(Inherited from Solution)
Version

This member is a wrapper for a member of a COM interface that has been superseded by a later version. The later version of this interface implements all members of earlier interfaces and additional new members. For information about this member as it is implemented in the later interface, including usage, remarks, and examples, seeVersion.

(Inherited from Solution)

Applies to