This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None); | |
config.AppSettings.Settings.Remove("CurrentUICulture"); | |
config.AppSettings.Settings.Add("CurrentUICulture", name); | |
config.Save(ConfigurationSaveMode.Modified, true); | |
// Force a reload of a changed section. | |
ConfigurationManager.RefreshSection("appSettings"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using (var stream = Assembly.GetExecutingAssembly() .GetManifestResourceStream("SalesForce.Tests.Required_AccountNames.txt")) | |
{ | |
using (var reader = new StreamReader(stream)) | |
{ | |
embededFile = reader.ReadToEnd(); | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class LogInjectionModule : Module | |
{ | |
protected override void Load(ContainerBuilder builder) | |
{ | |
//log4net added by extension | |
log4net.Config.XmlConfigurator.Configure(); | |
builder.Register<ILogger>((c, p) => new Log4NetLog(p.TypedAs<Type>())); | |
} | |
protected override void AttachToComponentRegistration(IComponentRegistry registry, IComponentRegistration registration) | |
{ |
NewerOlder