|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
xxxx.dll.config file for what? (Setting for DLL)VS2005
I have Class library that serve as COM. I put some setting to the My.Setting, the compile create file with name: xxxx.dll.config Now I read that config not work with DLL, I try that, and it's seem that true, this is not working. this is true? and why the compiler create this file on bin\debug folder? Hello mtczx***@yahoo.com,
> I have Class library that serve as COM. I put some setting to the try this> My.Setting, the compile create file with name: xxxx.dll.config > > Now I read that config not work with DLL, I try that, and it's seem > that true, this is not working. this is true? and why the compiler > create this file on bin\debug folder? ConfigurationManager.OpenExeConfiguration(System.Reflection.Assembly.GetExecutingAssembly().Location) --- WBR, Michael Nemtsev [C# MVP]. My blog: http://spaces.live.com/laflour Team blog: http://devkids.blogspot.com/ "The greatest danger for most of us is not that our aim is too high and we miss it, but that it is too low and we reach it" (c) Michelangelo dear MVP Michael Nemtsev
the work with such tools (.NET) become hard and hard. we are westing all our time to look after answer. take this simple example. you send us the mathod: ConfigurationManager.OpenExeConfiguration(System.Reflection.Assembly.GetExe cutingAssembly().Location) I try it, but the "config.AppSettings.Settings.Count" is 0, no setting loaded! why not have Clear answer for this porpose of Setting for DLL! the microsoft tell us that Open source is westing time, this is true, but Microsoft tools suffer from the same problem. Framework with no doc is not worth. So have any body with true solution? and more question. suppose we success to read the Setting, what about my.setting in DLL?, even we success to read the setting, it's not populate the natural my.setting object that VS create automatic code for? On 27 Mar, 10:46, Michael Nemtsev <nemt***@msn.com> wrote: Show quote > Hello mtczx***@yahoo.com, > > > I have Class library that serve as COM. I put some setting to the > > My.Setting, the compile create file with name: xxxx.dll.config > > > Now I read that config not work with DLL, I try that, and it's seem > > that true, this is not working. this is true? and why the compiler > > create this file on bin\debug folder? > > try this > > ConfigurationManager.OpenExeConfiguration(System.Reflection.Assembly.GetExecutingAssembly().Location) > > --- > WBR, Michael Nemtsev [C# MVP]. > My blog:http://spaces.live.com/laflour > Team blog:http://devkids.blogspot.com/ > > "The greatest danger for most of us is not that our aim is too high and we > miss it, but that it is too low and we reach it" (c) Michelangelo |
|||||||||||||||||||||||