Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
SetNamedNodeProperty method
Collapse the table of content
Expand the table of content

DataSource.SetNamedNodeProperty method

Sets the value of a named property for the specified XML node, which must be a nonattribute node in the main data source.

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

Public MustOverride Sub SetNamedNodeProperty ( _
	target As XPathNavigator, _
	name As String, _
	value As String _
Dim instance As DataSource
Dim target As XPathNavigator
Dim name As String
Dim value As String

instance.SetNamedNodeProperty(target, _
	name, value)


Type: System.Xml.XPath.XPathNavigator

An XPathNavigator object positioned at the XML node corresponding to a nonattribute node in the main data source, for which a named property is to be set.

Type: System.String

The name of the property to be set.

Type: System.String

The value to which the property will be set.


The specified XML node is invalid.


The specified property name is invalid.


The parameters passed to this method are a null reference (Nothing in Visual Basic).


The parameters passed to this method arenot valid. For example, they are of the wrong type or format.

Named properties allow users to associate strings with user-defined properties of XML element nodes in the main data source. The value of a named property can be set by using the SetNamedNodeProperty method. Use the GetNamedNodeProperty method to read the value of a named property.

Property values set with the SetNamedNodeProperty method are not saved when the form is saved.

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.

© 2015 Microsoft