XmlEvents.Item Property (String, String)

Gets an XmlEvent from the XmlEvents collection for binding an event handler by specifying the XPath of the underlying XML document node that can raise the event and the name of the secondary data source that supplies the data.

Namespace:  Microsoft.Office.InfoPath
Assembly:  Microsoft.Office.InfoPath (in Microsoft.Office.InfoPath.dll)

Syntax

'Declaration
Public MustOverride ReadOnly Default Property Item ( _
    xpath As String, _
    dataSourceName As String _
) As XmlEvent
    Get
'Usage
Dim instance As XmlEvents
Dim xpath As String
Dim dataSourceName As String
Dim value As XmlEvent

value = instance(xpath, dataSourceName)
public abstract XmlEvent this[
    string xpath,
    string dataSourceName
] { get; }

Parameters

  • xpath
    Type: System.String

    The XPath of the node to which the event handler is bound.

  • dataSourceName
    Type: System.String

    The name of the secondary data source.

Property Value

Type: Microsoft.Office.InfoPath.XmlEvent
The XmlEvent associated with the form node to which the event handler is bound.

Remarks

Important

The code to bind event handlers using the XmlEvents collection and XmlEvent class is not meant to be written by the developer in form code. The InternalStartup method and the event binding code within it are generated by InfoPath when you add event handlers using various user interface commands. You should not create the InternalStartup method or write any additional code within it yourself. For information about how to add event handlers using interface commands, see How to: Add an Event Handler.

See Also

Reference

XmlEvents Class

XmlEvents Members

Item Overload

Microsoft.Office.InfoPath Namespace