I need to be able to change between configuration files easily. The best way I think is to use multiple links to my application which supply the filename on the command line.
I tried the following (C#):
public static void Main(string args)
if (args.Length > 0)
AppDomain.CurrentDomain.SetupInformation.ConfigurationFile = args;
But the value of the ConfigurationFile
property does not change so I look in the Help:
quote:This property cannot be changed after the AppDomain has finished its first bind.
How can I get around this?
Hoping for ideas...