XmlUtilities.TryGetAttribute Method
Returns whether an XmlAttribute was obtained from the specified XmlNode.
Namespace: Microsoft.VisualStudio.Data.Schema.Project.Project.Utilities
Assembly: Microsoft.VisualStudio.Data.Schema.Project (in Microsoft.VisualStudio.Data.Schema.Project.dll)
Syntax
'Declaration
Public Shared Function TryGetAttribute ( _
node As XmlNode, _
attrName As String, _
<OutAttribute> ByRef attr As XmlAttribute _
) As Boolean
'Usage
Dim node As XmlNode
Dim attrName As String
Dim attr As XmlAttribute
Dim returnValue As Boolean
returnValue = XmlUtilities.TryGetAttribute(node, _
attrName, attr)
public static bool TryGetAttribute(
XmlNode node,
string attrName,
out XmlAttribute attr
)
public:
static bool TryGetAttribute(
XmlNode^ node,
String^ attrName,
[OutAttribute] XmlAttribute^% attr
)
public static function TryGetAttribute(
node : XmlNode,
attrName : String,
attr : XmlAttribute
) : boolean
static member TryGetAttribute :
node:XmlNode *
attrName:string *
attr:XmlAttribute -> bool
Parameters
- node
Type: System.Xml.XmlNode
The specified XmlNode
- attrName
Type: System.String
The name of the attribute to get
- attr
Type: System.Xml.XmlAttribute%
The resulting XmlAttribute
Return Value
Type: System.Boolean
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
See Also
Reference
Microsoft.VisualStudio.Data.Schema.Project.Project.Utilities Namespace