locked
Error in Time Tracker Application RRS feed

  • Question

  • User596449127 posted

    Hai all,

    I just downloaded Timetracker starter kit, and installed the application. But I'm getting the error, when I'm running the application. I'm using Visual Studio 2005 and Sql Server 2005 Enterprise Edition. Plz help me, How to solve this...

    Following is the Error Message.

     

    Server Error in '/TimeTracker' Application.

    An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

    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.Data.SqlClient.SqlException: An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

    Source Error:

    The source code that generated this unhandled exception can only be shown when compiled in debug mode. To enable this, please follow one of the below steps, then request the URL:

    1. Add a "Debug=true" directive at the top of the file that generated the error. Example:

      <%@ Page Language="C#" Debug="true" %>

    or:

    2) Add the following section to the configuration file of your application:

    <configuration>
       <system.web>
           <compilation debug="true"/>
       </system.web>
    </configuration>

    Note that this second technique will cause all files within a given application to be compiled in debug mode. The first technique will cause only that particular file to be compiled in debug mode.

    Important: Running applications in debug mode does incur a memory/performance overhead. You should make sure that an application has debugging disabled before deploying into production scenario.

    Stack Trace:

    [SqlException (0x80131904): An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)]
    System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) +734931
    System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) +188
    System.Data.SqlClient.TdsParser.Connect(Boolean& useFailoverPartner, Boolean& failoverDemandDone, String host, String failoverPartner, String protocol, SqlInternalConnectionTds connHandler, Int64 timerExpire, Boolean encrypt, Boolean trustServerCert, Boolean integratedSecurity, SqlConnection owningObject, Boolean aliasLookup) +820
    System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance) +628
    System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance) +170
    System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection) +130
    System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options) +28
    System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject) +424
    System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject) +66
    System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject) +496
    System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) +82
    System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +105
    System.Data.SqlClient.SqlConnection.Open() +111
    System.Web.DataAccess.SqlConnectionHolder.Open(HttpContext context, Boolean revertImpersonate) +84
    System.Web.DataAccess.SqlConnectionHelper.GetConnection(String connectionString, Boolean revertImpersonation) +197
    System.Web.Security.SqlRoleProvider.RoleExists(String roleName) +482
    System.Web.Security.Roles.RoleExists(String roleName) +242
    ASP.global_asax.Application_Start(Object sender, EventArgs e) +19


    Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.42
    <!-- [SqlException]: An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified) at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) at System.Data.SqlClient.TdsParser.Connect(Boolean& useFailoverPartner, Boolean& failoverDemandDone, String host, String failoverPartner, String protocol, SqlInternalConnectionTds connHandler, Int64 timerExpire, Boolean encrypt, Boolean trustServerCert, Boolean integratedSecurity, SqlConnection owningObject, Boolean aliasLookup) at System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance) at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance) at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection) at System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options) at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject) at System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject) at System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject) at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) at System.Data.SqlClient.SqlConnection.Open() at System.Web.DataAccess.SqlConnectionHolder.Open(HttpContext context, Boolean revertImpersonate) at System.Web.DataAccess.SqlConnectionHelper.GetConnection(String connectionString, Boolean revertImpersonation) at System.Web.Security.SqlRoleProvider.RoleExists(String roleName) at System.Web.Security.Roles.RoleExists(String roleName) at ASP.global_asax.Application_Start(Object sender, EventArgs e) --> 

    Thursday, January 3, 2008 5:14 AM

Answers

  • User555306248 posted

    Open "SQL Server Surface Area Configuration"

    then opne the "Surface Area Configuartion for Services and Connections "

    Under the Remote connection u have to enable the "Using both TCP/IP and Named  Pipes "

    then It will work..

    Also

    Try to set Data Source= "serverName" in you connectionString

    Data Source=.\SQLEXPRESS will work only on local m/c, It will not work if you host your site

    Check in web.config for connectionString, configure it according to your server name, password etc.

    In Time Tracking System, it uses inbuild Membership classes for user creation, updation etc..

    You have to register your DB with ASP.NET Membership classes by executing the command line utility in VS prompt

    aspnet_regsql, it will open one window, where you  have to configure DB.

    Hope it will help you, let me know.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, January 3, 2008 10:32 PM

All replies

  • User555306248 posted

    Open "SQL Server Surface Area Configuration"

    then opne the "Surface Area Configuartion for Services and Connections "

    Under the Remote connection u have to enable the "Using both TCP/IP and Named  Pipes "

    then It will work..

    Also

    Try to set Data Source= "serverName" in you connectionString

    Data Source=.\SQLEXPRESS will work only on local m/c, It will not work if you host your site

    Check in web.config for connectionString, configure it according to your server name, password etc.

    In Time Tracking System, it uses inbuild Membership classes for user creation, updation etc..

    You have to register your DB with ASP.NET Membership classes by executing the command line utility in VS prompt

    aspnet_regsql, it will open one window, where you  have to configure DB.

    Hope it will help you, let me know.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, January 3, 2008 10:32 PM
  • User555306248 posted

    Have you tried solution what I provided to you

    Let me know if this helpful to you, Post it on forum

    Sunday, January 6, 2008 10:41 PM
  • User596449127 posted

     Thank You Sir

    The information you provided, helped me a lot. Now I'm able to run that application.  

    Monday, January 7, 2008 11:26 PM
  • User555306248 posted

    Thanks for marking as answer, It will help to other people

    Tuesday, January 8, 2008 10:27 PM