Maybe you should try then
I don't think it is too hard to find a correct syntax... As I see the problem is in the building the correct string, not in the SelectNodes functionCode:String^ query = String::Concat("/PRODUCTS/FRUIT [CATEGORY= '", FoodCategoryLstBox.SelectedItem.ToString(), "' and ITEM = '" , ItemcmbBox.SelectedItem.ToString() , "']/ PRICE "); doc.SelectNodes(query);