如何从xml文件获取连接字符串 [英] How to get the Connection string from xml file

查看:177
本文介绍了如何从xml文件获取连接字符串的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我在xml文件中写入连接字符串.我想从此xmi文件中读取该连接字符串.我正在通过vb.net使用Windows窗体应用程序.

有人告诉我这个例子.

问候
Nanda Kishore.CH

Hi,

I am Writing connection string in xml file. i want to read that connection string from this xmi file. i am using windows form application with vb.net.

any one tell me the example.

Regards
Nanda Kishore.CH

推荐答案

您应该用Google搜索一下.无论如何,您可以使用XMLReader类读取/解析XML文件.您甚至可以在下面的MSDN链接中找到示例代码.

XMLReader的MSDN帮助 [将XmlReader类与C#一起使用 [ ^ ]
You should have googled a bit. Anyway, you can use the XMLReader class for reading/parsing your XML file. You even can find the sample code in the following MSDN link.

MSDN Help for XMLReader[^]

This is just for your reference: Using the XmlReader class with C#[^]


单击此处查看所有类型的连接字符串

http://www.connectionstrings.com/ [ ^ ]
click here for all types of connection strings

http://www.connectionstrings.com/[^]


这篇关于如何从xml文件获取连接字符串的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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