Setting the EPiServer connection string programmatically

Apr 02, 2015  

EPiServer connection string at runtimeA customer asked if it was possible to set the database connection string programmatically in an EPiServer site. In the customer's specific example they wanted to use a configuration database rather than store any configuration in a .config file.

This can be achieved by creating a custom IDatabaseFactory implementation that allows you to set the connection string programmatically: