从另一个项目访问在app.config值 [英] Accessing the app.config values from another project
问题描述
我在我的解决方案两个可执行的项目。一个是主节目,而另一只被成功安装后跑。主要程序(REase)有有,其他程序需要的connectionString(DBUpdater)的app.config文件。
I have two executable projects in my Solution. One is the primary program, and the other is only ran after a successful installation. The primary program (REase) has an app.config file that has the connectionString that the other program needs (DBUpdater).
如何的dbupdate访问的app.config为REase?
How can DBUpdate access the app.config for REase?
推荐答案
您可以使用的方法<一href="http://msdn.microsoft.com/en-us/library/system.configuration.configurationmanager.openmappedexeconfiguration.aspx"相对=nofollow> OpenMappedExeConfiguration
如果REase app.config文件名是由DBUpdater知道。
You could use the method OpenMappedExeConfiguration
if the app.config file name for REase is known by DBUpdater.
这篇关于从另一个项目访问在app.config值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!