You will notice some extra file in your VS2010 solution when you added the Azure web role project, 2 configuration files included which differentiate by the "Cloud" & "Local". It give us the flexibility to deploy our solution base on different environment. For example my case I'm using different DB.
Always remember to select the service configuration that you want to use base on your deployment. To retrieve the value dynamically on run time after deployment, refer below:
Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment.GetConfigurationSettingValue("SQLConnection")
0 comments :
Post a Comment