Can't get path to work in SelectSingleNode()
-
Hello, Sorry, this is a double post. I did not realize that this group was here before posting in VB group. I'm having trouble figuring out the correct search path to find the Appointment: where CompanyKey='Mr. Key' and Date='11/11/2018 12:00:00 AM'. I've tried numerous formats in sFmt2 and can't find the magic combination. sFmt1 works to find the first occurance of 'Mr. Key'. I've only listed a couple of tries. Can someone help? Thank you ' sFmt works; it retrieves the first occurance of "Mr. Key" Dim sFmt As String = "/MyCalendar/Appointments/Appointment[@CompanyKey='Mr. Key']" ' These do not work. Dim sFmt2 as string = "/MyCalendar/Appointments/Appointment[@CompanyKey='Mr. Key' and Date='11/11/2018 12:00 AM']" ' sFmt2 = "/MyCalendar/Appointments/Appointment[@CompanyKey='Mr. Key'][Date='11/11/2018 12:00 AM']" This is the xml file. - - - 11/11/2018 12:00:00 AM Add Appointment through XmlSerializer - 11/01/2018 12:00 AM Add Appointment through XmlDocument