在asp.net中搜索存储在xml中的数据 [英] search data in asp.net stored in xml

查看:78
本文介绍了在asp.net中搜索存储在xml中的数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尊敬的先生/女士,
感谢您解决我的第一个解决方案.现在我必须提供一种便利,当用户在文本框中键入文本并单击搜索"按钮时,如果它与xmlnode相匹配,则应在datagrid视图中显示存储在xml文件中的相关数据.例如,电影名称,星级,价格,年份和国家/地区数据存储在xml中.当用户在文本框中键入film-name(如果与该电影相关的全部信息匹配)时,应显示该名称.

Respected sir/Madam,
thank you for solving my first solution. now i have to provide a facility that when user type text in textbox and click on search button the relevent data stored in xml file should be displayed in datagrid view if it matches from xmlnode.for example filmname ,star,price,year and country data is store in xml.when user type film-name in textbox if it matches the entire information related to that film should be displayed .

推荐答案

这在很大程度上取决于XML您使用的结构.定位正确元素的一种方法是使用 SelectNodes [ http://www.java2s.com/Code/CSharp/XML/FindElementswithanXPathSearch.htm [ ^ ]
This depends greatly on the XML structure you use. One way to locate the correct element is to use SelectNodes[^] method.

Have a look at an example at: http://www.java2s.com/Code/CSharp/XML/FindElementswithanXPathSearch.htm[^]


这篇关于在asp.net中搜索存储在xml中的数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆