SQLConnection Help

Discussion in 'ASP .Net' started by Claudiu Tescu, Mar 31, 2005.

  1. I make an project in ASP that use SQL Server that is on the same computer at
    compilation time I have the problem :
    Login failed for user 'NOSTRU\IUSR_NOSTRU'.
    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: Login failed for user
    'NOSTRU\IUSR_NOSTRU'.

    Source Error:


    Line 31: // if (sqlConnection1.State==ConnectionState.Open)
    Line 32: // {
    Line 33: sqlDataAdapter1.Fill(dataSet11);
    Line 34: this.DataGrid1.DataBind();
    Line 35: // }


    Source File: c:\inetpub\wwwroot\Servici\WebForm1.aspx.cs Line: 33

    Stack Trace:


    [SqlException: Login failed for user 'NOSTRU\IUSR_NOSTRU'.]
    System.Data.SqlClient.ConnectionPool.GetConnection(Boolean&
    isInTransaction) +474
    System.Data.SqlClient.SqlConnectionPoolManager.GetPooledConnection(SqlConnectionString
    options, Boolean& isInTransaction) +372
    System.Data.SqlClient.SqlConnection.Open() +384
    System.Data.Common.DbDataAdapter.QuietOpen(IDbConnection connection,
    ConnectionState& originalState) +44
    System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32
    startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
    CommandBehavior behavior) +304
    System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord,
    Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior
    behavior) +77
    System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) +38
    Servici.WebForm1.Page_Load(Object sender, EventArgs e) in
    c:\inetpub\wwwroot\Servici\WebForm1.aspx.cs:33
    System.Web.UI.Control.OnLoad(EventArgs e) +67
    System.Web.UI.Control.LoadRecursive() +35
    System.Web.UI.Page.ProcessRequestMain() +750





    --------------------------------------------------------------------------------

    Version Information: Microsoft .NET Framework Version:1.1.4322.2032; ASP.NET
    Version:1.1.4322.2032


    How I can resolve this problem ?
     
    Claudiu Tescu, Mar 31, 2005
    #1
    1. Advertising

  2. Claudiu Tescu

    Brock Allen Guest

    This was discussed recently:

    http://groups-beta.google.com/group...brock ASPNET database&rnum=1#9c72794fbca0d600

    -Brock
    DevelopMentor
    http://staff.develop.com/ballen



    > I make an project in ASP that use SQL Server that is on the same
    > computer at
    > compilation time I have the problem :
    > Login failed for user 'NOSTRU\IUSR_NOSTRU'.
    > 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: Login failed
    > for user 'NOSTRU\IUSR_NOSTRU'.
    >
    > Source Error:
    >
    > Line 31: // if (sqlConnection1.State==ConnectionState.Open)
    > Line 32: // {
    > Line 33: sqlDataAdapter1.Fill(dataSet11);
    > Line 34: this.DataGrid1.DataBind();
    > Line 35: // }
    > Source File: c:\inetpub\wwwroot\Servici\WebForm1.aspx.cs Line: 33
    >
    > Stack Trace:
    >
    > [SqlException: Login failed for user 'NOSTRU\IUSR_NOSTRU'.]
    > System.Data.SqlClient.ConnectionPool.GetConnection(Boolean&
    > isInTransaction) +474
    >
    > System.Data.SqlClient.SqlConnectionPoolManager.GetPooledConnection(Sql
    > ConnectionString
    > options, Boolean& isInTransaction) +372
    > System.Data.SqlClient.SqlConnection.Open() +384
    > System.Data.Common.DbDataAdapter.QuietOpen(IDbConnection
    > connection,
    > ConnectionState& originalState) +44
    > System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32
    > startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
    > CommandBehavior behavior) +304
    > System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32
    > startRecord,
    > Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior
    > behavior) +77
    > System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) +38
    > Servici.WebForm1.Page_Load(Object sender, EventArgs e) in
    > c:\inetpub\wwwroot\Servici\WebForm1.aspx.cs:33
    > System.Web.UI.Control.OnLoad(EventArgs e) +67
    > System.Web.UI.Control.LoadRecursive() +35
    > System.Web.UI.Page.ProcessRequestMain() +750
    > ----------------------------------------------------------------------
    > ----------
    >
    > Version Information: Microsoft .NET Framework Version:1.1.4322.2032;
    > ASP.NET Version:1.1.4322.2032
    >
    > How I can resolve this problem ?
    >
     
    Brock Allen, Mar 31, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mark

    Can't open a SqlConnection

    Mark, May 9, 2005, in forum: ASP .Net
    Replies:
    3
    Views:
    734
  2. Nick
    Replies:
    0
    Views:
    423
  3. Amar
    Replies:
    3
    Views:
    354
    Trevor Benedict R
    Jun 11, 2004
  4. Randy Smith
    Replies:
    3
    Views:
    379
    Randy Smith
    May 5, 2005
  5. Michael D Murphy

    Help -- SQLConnection Problem

    Michael D Murphy, Sep 3, 2005, in forum: ASP .Net
    Replies:
    19
    Views:
    649
    Daniel Walzenbach
    Sep 6, 2005
Loading...

Share This Page