View3.GetSelectedNodes Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets a reference to an XMLNodesCollection collection that is populated with XML Document Object Model (DOM) nodes based on the current selection of items in a view.
public:
Microsoft::Office::Interop::InfoPath::XMLNodesCollection ^ GetSelectedNodes();
public Microsoft.Office.Interop.InfoPath.XMLNodesCollection GetSelectedNodes ();
abstract member GetSelectedNodes : unit -> Microsoft.Office.Interop.InfoPath.XMLNodesCollection
Public Function GetSelectedNodes () As XMLNodesCollection
Returns
A reference to the XMLNodesCollection.
Implements
Remarks
If no items are selected in a view, or if only text is selected, then the GetSelectedNodes method returns an empty collection.
Note: The GetSelectedNodes method will not return nodes based on the current selection if used in the OnClick event of a button in the view, since the focus is lost from the control that is intended to be in context. To avoid this behavior, use the GetSelectedNodes method from a custom task pane, menu or toolbar.