Server Error in '/' Application.

The ConnectionString property has not been initialized.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.InvalidOperationException: The ConnectionString property has not been initialized.

Source Error:


Line 28:             If parametro = "redirect" Then
Line 29:                 Dim dados As New dados.dados()
Line 30:                 Dim dr As System.Data.IDataReader = dados.retorna_datareader("select * from s_lojas where url = '" & Replace(LCase(Current.Request.Url.Host), "www.", "") & "' ")
Line 31: 
Line 32:                 While dr.Read()

Source File: E:\home\siriusfolh\siriusfolheados.com.br\web\App_Code\clsLoja.vb    Line: 30

Stack Trace:


[InvalidOperationException: The ConnectionString property has not been initialized.]
   System.Data.SqlClient.SqlConnection.PermissionDemand() +6034862
   System.Data.SqlClient.SqlConnectionFactory.PermissionDemand(DbConnection outerConnection) +27
   System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions) +156
   System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions) +22
   System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource`1 retry) +92
   System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry) +219
   System.Data.SqlClient.SqlConnection.Open() +101
   dados.dados.retorna_datareader(String sql) +337
   clsLoja.info(String parametro) in E:\home\siriusfolh\siriusfolheados.com.br\web\App_Code\clsLoja.vb:30
   clsLoja.loadConfig(String param) in E:\home\siriusfolh\siriusfolheados.com.br\web\App_Code\clsLoja.vb:98
   clsLoja.info(String parametro) in E:\home\siriusfolh\siriusfolheados.com.br\web\App_Code\clsLoja.vb:41
   _default..ctor() in E:\home\siriusfolh\siriusfolheados.com.br\web\default.aspx.vb:13
   ASP.default_aspx..ctor() in E:\home\siriusfolh\siriusfolheados.com.br\web\default.aspx.vb:912304
   __ASP.FastObjectFactory_app_web_viakh04e.Create_ASP_default_aspx() +52
   System.Web.Compilation.BuildResultCompiledType.CreateInstance() +31
   System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp) +104
   System.Web.UI.PageHandlerFactory.GetHandlerHelper(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath) +33
   System.Web.UI.PageHandlerFactory.GetHandler(HttpContext context, String requestType, String virtualPath, String path) +39
   System.Web.MaterializeHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +318
   System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step) +50
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +163


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.8.3928.0