Re: How to change ConnectionString name in web.config.

  •  11-20-2007, 9:57 AM

    Re: How to change ConnectionString name in web.config.

     
    In the ChatProvider implementation code ,
    You can override the method and use another way to return the connection string :
    for example:
     
    public class ExampleProvider : ChatProvider
    {
     
    public override string GetConnectionString()
     {
      //return base.GetConnectionString();//the default implementation is "ConnectionString"
     
      //now use another way to return the string :
      return System.Configuration.ConfigurationSettings.AppSettings["AnotherConnectionString"];

     }
     
    ....
     
    }
     
     
View Complete Thread