complex appSettings entries
-
In the
appSettings
section of theWeb.config
I want to store 'complex' types such as Collections. Currently to achieve this I am using class libries with aSettings.settings
file which allows this (with a nice interface). But I want to move the data to theWeb.config
file as this will allow me to change the values at runtime (essential). Does anyone have any ideas on how I can do this? At present, I am simply delimiting the entries with a special character. I fear this may be the best solution... cheers. -
In the
appSettings
section of theWeb.config
I want to store 'complex' types such as Collections. Currently to achieve this I am using class libries with aSettings.settings
file which allows this (with a nice interface). But I want to move the data to theWeb.config
file as this will allow me to change the values at runtime (essential). Does anyone have any ideas on how I can do this? At present, I am simply delimiting the entries with a special character. I fear this may be the best solution... cheers.Web.config is a Configuration file which help in setting up of a website. Change the Web.config at runtime will restart the application (i.e) all the session information will lose. You have to start the application again.
Castle Rider
What if I freeze??? Don't forget to breath...
My: Website | Yahoo Group | Blog Spot
-
In the
appSettings
section of theWeb.config
I want to store 'complex' types such as Collections. Currently to achieve this I am using class libries with aSettings.settings
file which allows this (with a nice interface). But I want to move the data to theWeb.config
file as this will allow me to change the values at runtime (essential). Does anyone have any ideas on how I can do this? At present, I am simply delimiting the entries with a special character. I fear this may be the best solution... cheers.Web.config is a Configuration file which help in setting up of a website. Change the Web.config at runtime will restart the application (i.e) all the session information will lose. You have to start the application again. The storing your 'Complex' collections in Web.config which is changing at runtime is a bad idea. Try to use XML files.
Castle Rider
What if I freeze??? Don't forget to breath...
My: Website | Yahoo Group | Blog Spot
-
Web.config is a Configuration file which help in setting up of a website. Change the Web.config at runtime will restart the application (i.e) all the session information will lose. You have to start the application again.
Castle Rider
What if I freeze??? Don't forget to breath...
My: Website | Yahoo Group | Blog Spot
I understand the Web.config But if I change a variable in the appSettings section on the server, then it will update live and users sessions are not lost - they get the new value and their session is maintained. But my question is about storing 'complex' types.
-
I understand the Web.config But if I change a variable in the appSettings section on the server, then it will update live and users sessions are not lost - they get the new value and their session is maintained. But my question is about storing 'complex' types.
boy.pockets wrote:
But if I change a variable in the appSettings section on the server, then it will update live and users sessions are not lost - they get the new value and their session is maintained.
I believe, that not going to happen.
boy.pockets wrote:
But my question is about storing 'complex' types.
All serializable collections can be stored in XML files.
Castle Rider
What if I freeze??? Don't forget to breath...
My: Website | Yahoo Group | Blog Spot
-
Web.config is a Configuration file which help in setting up of a website. Change the Web.config at runtime will restart the application (i.e) all the session information will lose. You have to start the application again. The storing your 'Complex' collections in Web.config which is changing at runtime is a bad idea. Try to use XML files.
Castle Rider
What if I freeze??? Don't forget to breath...
My: Website | Yahoo Group | Blog Spot
Thanks for taking the time to answer again. I hear what you are saying about xml files and will look into it (i know you can specify an 'external' file to extend the appSettings section). my experience is at odds with what you are saying about changing Web.config appSettings entries at runtime and loosing session information. Because I believe I am already doing it (I might be mistaken). Perhaps you could point me to some articles/doco backing up your point of view?
-
In the
appSettings
section of theWeb.config
I want to store 'complex' types such as Collections. Currently to achieve this I am using class libries with aSettings.settings
file which allows this (with a nice interface). But I want to move the data to theWeb.config
file as this will allow me to change the values at runtime (essential). Does anyone have any ideas on how I can do this? At present, I am simply delimiting the entries with a special character. I fear this may be the best solution... cheers.Here is the answer i was looking for: mysteries of configuration anyone making a medium-large scale web site should know about this :)