EvaluateDateTime¶
Returns the date-time offset value of the current node.
1 | |
Returns the date-time offset value of the node selected by the specified XPath expression.
1 | |
Parameters¶
string xpath
The XPath expression to evaluate. If not specified, the current node is used.
Returns¶
The date-time offset value of the selected node.
Remarks¶
The difference between $Xml.Evaluate and $Xml.EvaluateDateTime when both are used on a date-time value is:
$Xml.EvaluateDateTimereturns an object and returnsNULLwhen there is no actual value;$Xml.Evaluatereturns a string and returns an empty value (but notNULL) when there is no actual value.
Examples¶
Read the date-time value of a selected node¶
1 | |
Read a date-time value and handle a missing value¶
1 2 3 4 5 | |