使用App.config访问数据库连接 [英] Access DB connection with App.config
本文介绍了使用App.config访问数据库连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好......
我有一个Windows窗体,我添加了一个App.config,其中包含一个Access ConnectionString.如何在C#中读取此连接字符串?
我是为sqlconnection做到的,例如:
Hi all....
I have a windows form that I have added a App.config that is contains a Access ConnectionString.How can I read this connection string in C#?
I did it for sqlconnection like:
MyConnection.connectionString=configurationManager.connectionstring["MyDB"].connectionString;
但是关于olebd我一无所知……
But about olebd I have no idea......
推荐答案
看看
这篇关于使用App.config访问数据库连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文