Config files in .Net 3.5 +
I need to make use of a config file as often one does. In particular I am currently using the 'ChannelFactory' and just specifying an endpoint name. This works fine at the moment but the problem is it uses appname.exe.config and the application I am using makes DDE/etc calls to other applications that also use connections using ChannelFactory.
The problem is therefore each DDE'd application would require its own appname.exe.config unless I centralise it which is what I want to do.
There doesn't appear to be alot of advise on config files out there. Ideally I want to be able able to tell the framework where my config file is so that I can continue to use the ChannelFactory(string) call as is. But I realise this is probably unlikely and I see need to manually extract some sections and build up the endp开发者_StackOverflow中文版oint or some such.
Does anyone have any advise?
Thanks.
You can change the config file to be used during runtime and thus use a centralized app.config. See here for more info.
精彩评论