Follow up to This QuestionI took some very good advice and changed my code around a little bit and eliminated some If statements.I am not retrieving very much information but it looks so skinny now.  Is this a good thing?  Is there something that I should add to the code?Dim phoneNodeDim phoneNodeListReturnData = Set phoneNodeList = XmlDoc.SelectNodes(/Record/Case/CaseFormsLoad/PartyLoad/Party/PartyPhones/Phone)If phoneNodeList.Length > 0 Then    For Each phoneNode In phoneNodeList        If phoneNode.GetAttribute(ConfidentialFlag) = True Then            ReturnData = ReturnData & phoneNode.Getattribute(PhoneNum) & VbCrLf        End If    NextEnd IfThis code is very readable and simple.  Is there anything that I can do to make it shorter, and should I make it shorter?  it is a Script and not a fully compiled code.
Still pulling information from XML to insert into Word Document inside 3rd party application
vbscript
I see one point that seems almost obvious enough that I'm worried I might be missing something. A For Each is smart enough that its body isn't executed at all for an empty collection, so you can eliminate the test for the list having a length of 0:Dim phoneNodeDim phoneNodeListReturnData = Set phoneNodeList = XmlDoc.SelectNodes(/Record/Case/CaseFormsLoad/PartyLoad/Party/PartyPhones/Phone)For Each phoneNode In phoneNodeList    If phoneNode.GetAttribute(ConfidentialFlag) = True Then        ReturnData = ReturnData & phoneNode.Getattribute(PhoneNum) & VbCrLf    End IfNext