From: Naresh Ramaswamy Date: 2009-02-26T23:15:42+09:00 Subject: Re: Search for an Presence of an XML element in a array > > addresses = XPath.match(doc, "//addresses") > puts addresses.length #0 I have tried the above solution but it searches for the element and producess an array of these nodes. I would like to just know if Element 'SEND' exists do this elsif Element 'EXPECT' exists do this elsif Element 'WAIT' exists do this else p "Error" end I need a solution for the above. thanks, Naresh -- Posted via http://www.ruby-forum.com/.