Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can multiple C# apps use one App.Config file?

Tags:

c#

.net

We have many C# console apps that run on scheduled tasks. All of these apps have their own config file, which contain settings like our smtp server. If our smtp server ever changed, we would have to manually go into each config file and change it. Can multiple apps look at 1 config file on the C: drive, or is that considered bad practice? Using the database to store values is a no no.

like image 973
broke Avatar asked Mar 21 '12 19:03

broke


People also ask

Can you have multiple C?

Each repeat C-section is generally more complicated than the last. However, research hasn't established the exact number of repeat C-sections considered safe. Women who have multiple repeat cesarean deliveries are at increased risk of: Problems with the placenta.

Can I have 4 C-sections?

However, from the current medical evidence, most medical authorities do state that if multiple C-sections are planned, the expert recommendation is to adhere to the maximum number of three.”

How many cesarean births are allowed?

There's usually no limit to the number of caesarean sections that you can have. But the more caesareans you have, the longer each operation will take, and the higher your risk of complications becomes. If you've had a caesarean in the past, it's still possible to give birth to your baby vaginally.

Can you have 7 C-sections?

“There are some people who have had six or seven C-sections without any issues, and others with only one C-section whose next pregnancy is associated with a very difficult problem such as placenta accreta spectrum disorder, or a horrible adhesions (things stuck together),” he says.


1 Answers

You can point to external config files inside your application's configuration file like the following, and have all your applications use the same set of settings from a single file:

<appSettings file="c:\CommonSettings.config">
   <add key="MyKey" value="12"/> 
</appSettings>

For more information, you can read following articles:

  • AppSettings can Reference an External Config File
  • How to share custom application configuration settings across projects in .NET
like image 178
Teoman Soygul Avatar answered Sep 22 '22 07:09

Teoman Soygul